Wednesday, February 15, 2012

Exporting SPROCS

Ok, im trying to the difficult task of taking a DB i have on my laptop (SQL 2005) and putting it on my server (SQL 2000). How I got to this situation is somewhat od, just got roped in to do some part time development work.

Anyway heres my problem, I have transferred all the data and tables across no problems, but when I try to xfer my Stored Procedures across i get the following error.

Msg 208, Level 16, State 1, Line 1

Invalid object name 'sys.objects'.

I get to this point by going 'Generate Scripts' instead of Export Data, I then get it to generate the script making sure to click the generate as SQL 2000 property. Yet I still get this error. Any help you can offer is much appreciated. Thanks in advance

Dan

Hi,

I haven't tried to export sp's from 2005 -> 2000, but it seems that you have the wrong syntax in your sp's. Check out what syntax differences there are between 200 and 2005 regarding sysobjects etc.

What you are getting from "GENERATE AS SQL 2000" is that the wrapping t-sql is compliant with sql 2000, not what you have written in your sp's.

Regards

No comments:

Post a Comment