Friday, March 23, 2012

Incorrect syntax for backup

Hi All,
I have the following issue.
I have upgraded MS SQL Server 6.5 to 7.0.
I also have SQL Server 2000.
I have registered the SQL 7.0 server in the SQL 2000 server group.
When I run the following backup command in the query analyzer, that
runs ok with all the databases in SQL 2000 but not in the SQL 7.0.
Backup database abc to disk='\\NTDR1\DBBack\abc.dat' WITH INIT
I get the following error
Incorrect syntax near the keyword 'database'.
I have checked the permission and I am loggin as sa.
Could anyone please help me why I am unable to run the above command
for the database upgraded from SQL 6.5 to SQL 7.0, whereas the same
command works fine for SQL 2000.
I do appreciate your help.
Thanks a million in advance.
Best regards,
mamunRun this
Exec sp_dbcmptlevel 'DB NAME'
Does it say 65 ?
If it does change it to
Exec sp_dbcmptlevel 'DB NAME',70
--
Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
"Mamun" <mamun_ah@.hotmail.com> wrote in message
news:6012e7ab.0310071109.53289600@.posting.google.com...
> Hi All,
> I have the following issue.
> I have upgraded MS SQL Server 6.5 to 7.0.
> I also have SQL Server 2000.
> I have registered the SQL 7.0 server in the SQL 2000 server group.
> When I run the following backup command in the query analyzer, that
> runs ok with all the databases in SQL 2000 but not in the SQL 7.0.
> Backup database abc to disk='\\NTDR1\DBBack\abc.dat' WITH INIT
> I get the following error
> Incorrect syntax near the keyword 'database'.
> I have checked the permission and I am loggin as sa.
>
> Could anyone please help me why I am unable to run the above command
> for the database upgraded from SQL 6.5 to SQL 7.0, whereas the same
> command works fine for SQL 2000.
>
> I do appreciate your help.
> Thanks a million in advance.
> Best regards,
> mamun|||"Mamun" <mamun_ah@.hotmail.com> wrote in message
news:6012e7ab.0310071109.53289600@.posting.google.com...
> I have the following issue.
> I have upgraded MS SQL Server 6.5 to 7.0.
> I also have SQL Server 2000.
> I have registered the SQL 7.0 server in the SQL 2000 server group.
> When I run the following backup command in the query analyzer, that
> runs ok with all the databases in SQL 2000 but not in the SQL 7.0.
> Backup database abc to disk='\\NTDR1\DBBack\abc.dat' WITH INIT
> I get the following error
> Incorrect syntax near the keyword 'database'.
> I have checked the permission and I am loggin as sa.
>
> Could anyone please help me why I am unable to run the above command
> for the database upgraded from SQL 6.5 to SQL 7.0, whereas the same
> command works fine for SQL 2000.
>
The MSSQLServer service must be running under the context of a service
account that has update permissions on your target UNC.
http://support.microsoft.com/default.aspx?scid=kb;en-us;207187&Product=sql2k
Steve
Steve

No comments:

Post a Comment