Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
ceema
Yak Posting Veteran
80 Posts |
Posted - 2006-06-05 : 01:30:38
|
| Hello, Is there any sql command to get all the table names with it's structure(like columnname,datatype,size,key) from a database?Like in my database I have 50 tables, I have to get the table names with the the complete structure( actually my aim is to copy it and take printout).ThanksCeema |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2006-06-05 : 01:38:32
|
use INFORMATION_SCHEMA.COLUMNS KH |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2006-06-05 : 01:50:54
|
If your purpose is for documentation, you might want to consider some of the db design tools available in the market. Just search this site or google for it. KH |
 |
|
|
cmdr_skywalker
Posting Yak Master
159 Posts |
Posted - 2006-06-05 : 02:29:00
|
| You can use the SQL diagram and print the layout.If you need the DDL, use the Enterprise Manager and copy the Stmt to the document.If you want a report without spending, use the INFORMATION_SCHEMA tables. If you have some money, you can use Erwin, EA, etc.May the Almighty God bless us all! |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2006-06-05 : 02:42:25
|
| Also make use Generate SQL Script feature from EMMadhivananFailing to plan is Planning to fail |
 |
|
|
ceema
Yak Posting Veteran
80 Posts |
Posted - 2006-06-05 : 02:47:16
|
| Hello, Thanks you.'INFORMATION_SCHEMA.COLUMNS' will do.regardsCeema |
 |
|
|
|
|
|
|
|