Quote:
I would like to list the extended properties of a table using:
select *
from ::fn_listextendedproperty(default, default, default, default,
default,
default, default) |
This code, according to the Books Online topic, will list extended
properties for the database. If you don't specify a TABLE NAME, how is the
code supposed to know which table's extended properties you want? Should it
guess, or take the first alphabetical table name, or the last table created,
or ...?
CREATE TABLE dbo.foo(bar INT)
GO
EXEC sp_addExtendedProperty
'description',
'This is what happens when...',
'user',
'dbo',
'table',
'foo',
'column',
'bar'
SELECT
name,
value
FROM
::fn_listextendedproperty
(
NULL,
'user',
'dbo',
'table',
'foo',
'column',
'bar'
)
DROP TABLE foo
GO
Follow-ups set to .programming only -- .dts and .tools dropped.