Hello, everyone:
How to get the column name from a table? Thanks.
ZYTTwo ways to get column names:
select sc.name from syscolumns sc where sc.id = object_id('<tablename>')
OR
select * from <tablename> where 1=2
HTH.|||or:
select column_name
from information_schema.columns
where table_name = ...
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment