|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
SQL 7 column names
i'm using sql 7 and i need to get the column names. i can see them using sp_columns tableName but it returns alot of junk that i don't need. anyone know a way to get JUST the column names?
thanks |
|
#2
|
||||
|
||||
|
Code:
SELECT c.[name] FROM syscolumns AS c WITH (NOLOCK) INNER JOIN sysobjects AS s WITH (NOLOCK) ON c.id = s.id AND s.[name] = 'MyTableName' Hope this helps. |
|
#3
|
|||
|
|||
|
For mysql
I understand the creator of this thread has his issue solved, but for all who wants an answer on this question, and using mysql, here it is (dead simple ey?):
SHOW COLUMNS FROM table_name |
![]() |
| Viewing: Dev Shed Forums > Databases > Database Management > SQL 7 column names |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|