November 10, 2011 at 11:51 am
I gave the wrong table in the SP it compiled fine and gave me run time error. Again i gave the wrong column name for a table it throws compile time error.
This seems to be conflicting. Can anybody explain me ?
November 10, 2011 at 12:02 pm
for objects...tables,procs or views, a feature of stored procedure is delayed name resolution...of the object doesn't exist at creation time, it still compiles, but will fail at execution time.
so you can create procs out of object dependancy order, and they are still "ok" later.
columns do not have that feature...only their parent object...so the algebraizer finds the object(table or view) but raises the error becase the column doesn't exist.
it's the behavior of SQL server.
the work around is to use dynamic SQL if you are referencing non-existant columns yet.
Lowell
November 10, 2011 at 12:08 pm
Go it, Thanks Lowell
ek
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy