Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Populate sql table field descriptions programatically Expand / Collapse
Author
Message
Posted Friday, March 15, 2013 6:49 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Yesterday @ 10:13 AM
Points: 1, Visits: 63
I am trying to update my sql table field descriptions programatically, but I am getting an error.
------------------------------
use NCOS
GO

EXEC sp_updateextendedproperty
@name = N'MS_Description', @value = 'Your description',
@level0type = N'Schema', @level0name = 'NCOS',
@level1type = N'Table', @level1name = 'NCOS_Data',
@level2type = N'Column', @level2name = 'NC_Prospect_Name';

Error:

Server: Msg 15600, Level 15, State 1, Procedure sp_updateextendedproperty, Line 42
An invalid parameter or option was specified for procedure 'sp_updateextendedproperty'.
Post #1431508
Posted Friday, March 15, 2013 2:32 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: 2 days ago @ 1:04 PM
Points: 2,663, Visits: 5,798
I cannot test this at the moment, but I think..

You are specifying the database name NCOS as the Schema name. It knows the database name already, so just replace the 'NCOS' with 'dbo' or whatever is appropriate for the schema name.

Mike John



Post #1431757
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse