Click here to Skip to main content
15,561,125 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
EXECUTE sys.sp_catalogs 'server\instance'

returns, once the instance has been configured for "DATA ACCESS" by doing this:
EXEC sp_serveroption 'server\instance', 'DATA ACCESS', TRUE

this:
CATALOG_NAME                DESCRIPTION
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
x                   NULL
y               NULL
z               NULL
master              NULL
model               NULL
msdb                NULL
Northwind           NULL
ReportServer$instance       NULL
ReportServer$instanceTempDB NULL
tempdb              NULL
r               NULL

And someone has suggested using UPDATE, that I could set DESCRIPTION (the ANY of the title above) to what I want the value to be.

Given that the value presently is NULL, and whatever that datatype might be that it represents, how could UPDATE be of any use? This output is tabular but it's not necessarily coming from any table; the stored procedure could be leveraging unexposed facility or other. But that's besides the point here.

How can I retain this "tabulation" nature without knowing where this system catalog data is coming from, or better yet without having to create my own tabulation, how can I alter the DESCRIPTION data itself and change NULL to ...
whatever?
Posted
Comments
PIEBALDconsult 18-Jan-15 17:51pm    
I don't know, and I tried a few things myself. What I _do_ know is that the Descriptions of columns are stored in sys.extended_properties , so I expect it will involve that somehow.
RedDk 18-Jan-15 18:06pm    
processing ...

Well, I see class, class_desc, major_id, name, and value. Ok.

But the thing is that from a SELECT standpoint I'm looking at the DESCRIPTION (of) an object that has no exposure presumeably because its <italic>AT the level of the server and the instance. There wouldn't be a servicable table anywhere there except for in System Databases (hence sys.extended_properties ... or sys.sp_serveroptions ... etc)

[Edit}
The other big tell is that NONE of the values is anything other than NULL
[Edit]
PIEBALDconsult 18-Jan-15 18:14pm    
Not necessarily. One of the things I tried (with little hope that it would actually work) was to set an Extended Property on a database, name it Description, give it a value, and see if it would "just magically" show up. I also tried naming it MS_Description (which is the name of a Description for a column). Neither worked of course.
RedDk 18-Jan-15 18:19pm    
I'm not going to reply to anything unconstructive, thanks.

Whatever happened to show some code?
PIEBALDconsult 18-Jan-15 18:25pm    
Hey, if you've got other offers, go for it. In the meantime, this is an interesting question. I also just tried creating a new database (SQL Server 2014) to see if there was a place to set a Description, but I saw none. You may find it's an obsolete feature.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900