create database script - sql server 2000 compatible

I am running Sql Server Management Studio Express 2005 and have a database that I need to install on a remote sql server box running Sql Server 2000 (8.0.194).

I am connected to the remote server thru the Object Explorer.  I though the easiest way to recreate the database was to script the database and tables and then load the data.  However, when I tried to run the create database script I got the following errors:

Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'ENABLE_BROKER'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'AUTO_UPDATE_STATISTICS_ASYNC'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'DATE_CORRELATION_OPTIMIZATION'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'TRUSTWORTHY'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'ALLOW_SNAPSHOT_ISOLATION'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'PARAMETERIZATION'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'CHECKSUM'.
Msg 102, Level 15, State 6, Line 1
Incorrect syntax near 'DB_CHAINING'.

Here is my create database script:






USE [master]
GO
/****** Object:  Database [databasename]    Script Date: 06/27/2009 13:56:20 ******/
CREATE DATABASE [databasename] ON  PRIMARY
( NAME = N'databasename', FILENAME = N'c:\Program Files (x86)\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\databasename.mdf' , SIZE = 2048KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
 LOG ON
( NAME = N'databasename_log', FILENAME = N'c:\Program Files (x86)\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\databasename_log.ldf' , SIZE = 1024KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
 COLLATE SQL_Latin1_General_CP1_CI_AS
GO
EXEC dbo.sp_dbcmptlevel @dbname=N'databasename', @new_cmptlevel=80
GO
IF (1 = FULLTEXTSERVICEPROPERTY('IsFullTextInstalled'))
begin
EXEC [databasename].[dbo].[sp_fulltext_database] @action = 'enable'
end
GO
ALTER DATABASE [databasename] SET ANSI_NULL_DEFAULT OFF
GO
ALTER DATABASE [databasename] SET ANSI_NULLS OFF
GO
ALTER DATABASE [databasename] SET ANSI_PADDING OFF
GO
ALTER DATABASE [databasename] SET ANSI_WARNINGS OFF
GO
ALTER DATABASE [databasename] SET ARITHABORT OFF
GO
ALTER DATABASE [databasename] SET AUTO_CLOSE OFF
GO
ALTER DATABASE [databasename] SET AUTO_CREATE_STATISTICS ON
GO
ALTER DATABASE [databasename] SET AUTO_SHRINK OFF
GO
ALTER DATABASE [databasename] SET AUTO_UPDATE_STATISTICS ON
GO
ALTER DATABASE [databasename] SET CURSOR_CLOSE_ON_COMMIT OFF
GO
ALTER DATABASE [databasename] SET CURSOR_DEFAULT  GLOBAL
GO
ALTER DATABASE [databasename] SET CONCAT_NULL_YIELDS_NULL OFF
GO
ALTER DATABASE [databasename] SET NUMERIC_ROUNDABORT OFF
GO
ALTER DATABASE [databasename] SET QUOTED_IDENTIFIER OFF
GO
ALTER DATABASE [databasename] SET RECURSIVE_TRIGGERS OFF
GO
ALTER DATABASE [databasename] SET  ENABLE_BROKER
GO
ALTER DATABASE [databasename] SET AUTO_UPDATE_STATISTICS_ASYNC OFF
GO
ALTER DATABASE [databasename] SET DATE_CORRELATION_OPTIMIZATION OFF
GO
ALTER DATABASE [databasename] SET TRUSTWORTHY OFF
GO
ALTER DATABASE [databasename] SET ALLOW_SNAPSHOT_ISOLATION OFF
GO
ALTER DATABASE [databasename] SET PARAMETERIZATION SIMPLE
GO
ALTER DATABASE [databasename] SET  READ_WRITE
GO
ALTER DATABASE [databasename] SET RECOVERY SIMPLE
GO
ALTER DATABASE [databasename] SET  MULTI_USER
GO
ALTER DATABASE [databasename] SET PAGE_VERIFY CHECKSUM  
GO
ALTER DATABASE [databasename] SET DB_CHAINING OFF

Is there an easier way to create the database on the remote server?  I don't have access to remote desktop into the server and place a backup on the drive and then restore or place the .mdf file and attach.  I have to create the database locally from within SQL Server Management Studio Express 2005 object explorer.

Any help is appreciated.
Thanks.
-Dman100-Software ConsultantAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Guy Hengel [angelIII / a3]Billing EngineerCommented:
you should, instead of developing on a sql 2005 instance, develop on the sql 2000 instance, avoiding all these problems. upgrading is much easier than downgrading.
so, my suggestion is:
install sql 2000 express edition/msde as a named instance (on the same box), and you can still use the sql 2005 management studio to connect to it.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
8080_DiverCommented:
In looking at your script . . . what are you setting ENABLE_BROKER , etc., to?  You have specified an ON/OFF setting for the other things but nothing for those. ;-)
0
8080_DiverCommented:
You might want to try using Management Studio to script out the databse  that you have created and then look at the script that it generates and see how it looks. ;-)
0
Racim BOUDJAKDJIDatabase Architect - Dba - Data ScientistCommented:
In addition to angelIII's sound advice...

Actually the message error tells you exactly that the options that are unknown in a SQL 2000 compatible environment.  Simply take them away from the script and re run
0
-Dman100-Software ConsultantAuthor Commented:
Thanks guys...I was able to use Sql Publishing Wizard to target sql server 2000 and script out the schema and data.  It worked like a charm.  I appreciate the suggestions though.

Regards.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server 2005

From novice to tech pro — start learning today.