I'm using MS SQL, I'm wondering if anyone knows a way for me to retrieve a column's description in a query. I can get everything else, Identity seed, data type etc. just can't seem to find any info on retrieving the description.
Thanks,
Basscyst
__________________
Helping to build a bigger box. - Adam Matthews
Last edited by guelphdad; 01-05-2007 at 04:40 AM..
Reason: add database
SELECT *
FROM INFORMATION_SCHEMA.Tables T JOIN INFORMATION_SCHEMA.Columns C
ON T.TABLE_NAME = C.TABLE_NAME
WHERE T.TABLE_NAME = 'yourTablename'
ORDER BY C.COLUMN_NAME
__________________
If this post contains any code, I may or may not have tested it. It's probably just example code, so no getting knickers in a bunch over a typo, OK? If it doesn't have basic error checking in it, such as object detection or checking if objects are null before using them, put that in there. I'm giving examples, not typing up your whole app for you. You run code at your own risk.
Bored? Visit http://www.kaelisspace.com/
Yeah, all the examples I've found give me that data, but it doesn't include the data I'm interested in. The highlighted field in the image below is what I am looking for.
Thanks,
Basscyst
__________________
Helping to build a bigger box. - Adam Matthews