Database Settings or SQL2K Compatibility ?

  • Hi,

    I just upgraded to SQl Server 2000 from 7, and realized that all my reports created with existing scripts no longer work fine. The reports appear corrupt. Below is an example of a report script:

    declare @vSubject varchar(30),

    @vMessage varchar(20)

    Begin

    Select @vSubject = 'Report as of :' + convert(varchar,getdate()-1,1)

    Select @vMessage = 'Automatic Report'

    EXEC xp_sendmail @recipients = 'Bob',

    @query = "FetchEmailData",

    @attachments = 'DailyReport.wri',

    @subject = @vSubject,

    @message = @vMessage,

    @attach_results = 'TRUE',@width = 250

    End

    The DailyReport.wri file appears corrupt when opened with notepad. The same happens to .xls reports too.

    Are there settings I need to change or is this a SQL2K issue ?. Any suggestions/help would be appreciated. SQL Server 2000 runs on Windows 2000 Adv.

    Thanks.

  • Much is changed from sql7 to sql2k. You would probably want to set the compatibility level accordingly.

    Follow this link for more info:

    http://msdn.microsoft.com/library/en-us/tsqlref/ts_sp_da-di_5c8c.asp?frame=true

    --

    -oj

    Rac v2.1 Public Beta RELEASED.

    http://www.rac4sql.net

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply