Groups | Blog | Home
all groups > sql server new users > may 2007 >

sql server new users : Import from SQL 6.5 to 2005


Steve Gr
5/30/2007 12:00:00 AM
Hi,

I have some tables that I'd like to copy from a SQL6.5 database into a SQL
2005 database.
The table structure and data needs to come across, ideally automatically so
I don't have to create the tables first in 2005.
What is the best way to do this?

Thanks,
SW

Russell Fields
5/30/2007 11:12:50 AM
SW,

You should be able to use the Import and Export Wizard to get data and
tables from 6.5 to 2005. You can get to the wizard by right mouse click on
a database, then choose Tasks / Import and go through the prompts.

You can read about this in the Books Online topic "Copying Databases from
SQL Server 6.5 or Earlier".

RLF
[quoted text, click to view]

Russell Fields
5/30/2007 1:35:01 PM
Steve,

It has been several years since I ran instcat.sql, but it caused me no
problem at that time. It updated a few things so that the newer tools (e.g.
7.0 Enterprise Manager talking to 6.5 servers) worked just fine.

http://support.microsoft.com/kb/137636 says: The system catalog stored
procedures installed by INSTCAT.SQL are backward- compatible.

I Googled a few people who have run it for 2005 to 2000 connections and they
had no problems, either. Although a brief look did _not_ find someone
commenting on 2005 connecting to 6.5, I would not expect a problem.

RLF
[quoted text, click to view]

Steve Gr
5/30/2007 6:06:37 PM
Russell,

Thanks for your input. It seems that I have to run a script called
instcat.sql in order to proceed.
What isn't clear though its probably me being overcautious is what are the
consequences of running this script? I assume that I have to get the version
of the script from a 2005 installation, and then run it on the 6.5 server.

Is there a rollback script if anything goes wrong?

Regards,

SW

[quoted text, click to view]

Hari Prasad
5/31/2007 12:00:00 AM
Hello,

Instcat do not have any issues, I have used that multiple times some time
back.

If you do not want to run the INSTCAT.SQL. What you can do is:- (This is a
manuall process)

1. Create the script of all tables includes dependents from SQL 6.5 (Use 6.5
enterprise manager)
2. Execute the script in SQL 2005
3. Extract the data from tables in SQL 6.5 using BCP OUT
4. Copy the files to SQL 2005 server
5. use BCP IN or BULK insert into load the data

Thanks
Hari


[quoted text, click to view]

Steve Gr
5/31/2007 12:00:00 AM
Thanks to all for your input.

I've done this by running instcat.sql on the 6.5 server, then by using the
import wizard to import the tables first into a SQL 2000 database, then from
there into my SQL2005 database.

I kept getting errors when I tried to import directly from 6.5 to 2005,
telling me that SQL2005 couldn't obtain a rowset and I should check if the
data actually exists.

Regards,
SW


[quoted text, click to view]

Roger Wolter[MSFT]
5/31/2007 7:18:45 AM
It's too late now but for next time, if you attach your 6.5 database to SQL
2000 and then attach that database to SQL 2005, all the conversion will
happen automagically. I assumed you didn't have SQL 2000 available if you
were working with 6.5 databases.

--
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm

[quoted text, click to view]
Steve Gr
6/1/2007 12:00:00 AM
Thanks Roger.
Yes I didn't mention I had the luxury of a SQL 2000 database online. It
certainly made things easier, and could have made it even easier!

Regards,
SW

[quoted text, click to view]

Erland Sommarskog
7/29/2007 9:41:09 PM
Roger Wolter[MSFT] (rwolter@online.microsoft.com) writes:
[quoted text, click to view]

Roger, you can't do that. There is only single piece of software that is
capable to read an SQL 6.5 database, and that is SQL Server 6.5. The
structure in 6.5 was completely different from SQL 7. There are no mdf
or ldf files, instead databases existed on "devices" which were file that
could contain several databases, or fragments of several databases.

The same also applies to backups. The only software that can read an
SQL 6.5 backup is SQL Server 6.5.



--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
AddThis Social Bookmark Button