Tuesday, March 6, 2012

"owner name" cannot be omitted in sql 2005 querries?

Dear All,

Our project was done in SQL 2000, now we are migrating to 2005.
however, there are lots of command such as:

a) SELECT * FROM myTableName

which, shall be

b) SELECT * FROM myLoginId.myTableName

both (a) and (b) are ok in sql 2000, as long as you login with
myLoginId, but, only (b) works in sql 2005.

seems in sql 2005, you can not omit the "Owner Name" when speifying a
table, unless the table's owner is 'DBO'.

which means, even if I login with myLoginId, I have to use the detailed
format (b),not (a).

this causes trouble in our project -- developed in sql 2000, hundreds
of command omitted the owner name prefix, troublesome to modify one by
one.

Any workaround or suggestions, please? Thanks.Hi, athos

Please do not "multi-post". If you really want to send a message to
more than one newsgroup, post a single message with all the newsgroups
in the "To:" field (this is called "cross-posting". See:
http://www.aspfaq.com/etiquette.asp?id=5003
http://www.aspfaq.com/etiquette.asp?id=5004

See my answer in the microsoft.public.sqlserver.server newsgroup:
http://groups.google.com/group/micr...ede4803725ce795

Razvan|||Dear Razvan,

thanks for your information. Sorry I never noticed the line saying
"(Separate multiple groups with commas)". thanks.

yours
Athos.

No comments:

Post a Comment