Rich (2/27/2009)
Longy (2/27/2009)
Rich (2/27/2009)
Based on the queries supplied, you should get 1 and 1, because the first statement includes the wildcard at the beginning, so the # SHOULD be returned.The answer says
"Table variable names inside tempdb starts with '#' followed by hex string"
In which case it wouldn't find it using the name
Oops. Too early in the AM.
Yeah, I thought exactly the same thing at first, but after re-reading it spotted that!