Wednesday, March 21, 2012

How to get Table owner using SMO

Is there any way to discover owner of a table, stored procedure?

I can see 'Owner' property only in Schema class, not in Table class.

Of course in 99% cases schema owner owns all schema-contained objects, so the question is what to do when it is not the case?

Thanks.

Alexander Sychev.

At this time you cannot get the Owner for schema owned objects. This is something we need to look into for the upcoming release.sql

No comments:

Post a Comment