Hi, this is my opening blog. I intend to use this space to discuss my SQL 2000 exploits, and to build up some blogging experience.

As an opener, I'd like to describe a scenerio I've seen in news group posts - 'execution of a stored procedure as a view'. The normal work around for this is to use the openrowset provider. However, this only works if the stored procedure in question does not use temporary tables to build its result set. instead you will have to consider encoding the stored procedure as a UDF (this may also have its problems if the proc itself relies on the exec statement)

I now have an update to this - thanks to OJ on the sql newsgroup for following this one up - its late, so I'll publish the full transcript tomorrow, but in short, if the stored proc does build its result set using a temporary table, then the query text in ht eopenrowset, or openquery provider will look similar to this 'set fmt_only off;exec my_proc'. It turns out that the first 'thing' the provider does when connecting back into SQL is to get a column list using fmtonly, which don't exist until the proc is executed, hence setting this request off. Full example to follow tomorrow.