Solved

Use of sp_addextendedproperty to add descriptions on Tables & columns when Owner NOT dbo but PSEUDEOuser USER

Posted on 2004-08-23
3
1,926 Views
Last Modified: 2012-05-05
How can I add descriptions to EITHER a table OR a column when the table owner is NOT dbo but DOES have db_owner role?

all of the examples given:

exec sp_addextendedproperty N'MS_Description', N'This is a description', N'user', N'dbo', N'table', N'table_name'

I want to assume that I do NOT know the username so it's not just N'other user' (in the 3rd to the end parmameter)
I really want to use the USER pseudo column and assume the one adding the description is the OWNER (this is a safe assumption to make)

Thanks!
0
Comment
Question by:strongs120
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 34

Accepted Solution

by:
arbert earned 500 total points
ID: 11877039
I've never found it possible to do this (it's a little bit disappointing that descriptors aren't easier to work with in SQL).  Just a suggestion, since you have to call a proc to do it anyway, setup your "Meta Data" table and insert all your extended properties into this user create table--you have more options and more flexibility in the future using your own.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
Via a live example, show how to setup several different housekeeping processes for a SQL Server.
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question