| Author |
Topic |
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-07-24 : 02:13:11
|
| Hi, Is there any command so that i get whole Table Structure ? |
|
|
elancaster
A very urgent SQL Yakette
1208 Posts |
Posted - 2008-07-24 : 02:14:42
|
| you can generate the script for it through management studio / enterprise managerEm |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-07-24 : 02:17:54
|
| Sorry , I can't do that. I can not run enterprise manager , it is on serverwhich is beyond me. |
 |
|
|
ratheeshknair
Posting Yak Master
129 Posts |
Posted - 2008-07-24 : 02:35:47
|
| How you connect to server???RKNAIR |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-07-24 : 02:39:46
|
| I have only the DSN name , i upload the file and retreving the data,This time i need to know how many tables my database have and what the structure of it ? |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2008-07-24 : 02:48:35
|
| EXEC sp_help 'table_name'MadhivananFailing to plan is Planning to fail |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-07-24 : 02:56:13
|
| Thanks madhivanan, Thanku very much |
 |
|
|
VGuyz
Posting Yak Master
121 Posts |
Posted - 2008-07-24 : 08:29:55
|
| By clicking the table_name and then press Alt+F1 |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-08-12 : 07:50:01
|
| EXEC sp_help 'table_name'Through This I get several things.How can i get only Table Structure ?B'cos i have to print it on my asp form, and it is very typical to print whole result.Is there any way so that i can get only Table structure ? {Second Result SET in Whole result} |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-08-12 : 07:54:59
|
quote: Originally posted by Nitin Bansal I have only the DSN name , i upload the file and retreving the data,This time i need to know how many tables my database have and what the structure of it ?
Cant you use INFORMATION_SCHEMA views for this?INFORMATION_SCHEMA.TABLES for table info and INFORMATION_SCHEMA.COLUMNS for column info |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-08-12 : 08:00:54
|
| How can i use this INFORMATION_SCHEMA ? |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-08-12 : 08:10:12
|
quote: Originally posted by Nitin Bansal How can i use this INFORMATION_SCHEMA ?
SELECT * FROM INFORMATION_SCHEMA.TABLES will give you details of all tables in your dband SELECT * FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='YourTable'will give you columns in the particular table |
 |
|
|
Nitin Bansal
Starting Member
13 Posts |
Posted - 2008-08-12 : 08:56:51
|
| Thanks Mr. visakh murukes |
 |
|
|
|