Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2006-10-05 : 07:58:00
|
marc writes "Hi,I exported a database as a .sql file. It is plm 900MB. This script file contains all the sql to create tables plus all the data. I want to use this .sql file to create a new SQL 2005 database but see no way to transfer this. Is using .sql files as a source for importing data possible at all?Thanks!" |
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2006-10-05 : 08:07:00
|
You can use SQLCMD utility for this:sqlcmd -S <servername> -U <username> -P <password> -i <sqlfilename> Harsh AthalyeIndia."Nothing is Impossible" |
|
|
gsgill76
Posting Yak Master
137 Posts |
Posted - 2006-10-05 : 16:14:41
|
marc --you said, you had created a .sql file which contains script file contains all the sql to create tables plus all the data.May i know how did you generate this file. that is what i am looking for. I mean a .sql which contains Schema(constaints, insexes..etc) + the data of the table(in editable form)Thanks,Regards.Gurpreet S. Gill |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2006-10-05 : 16:16:45
|
You don't need to use SQLCMD for this, but you can of course. The other option is to open the sql file in a query window in Management Studio and just run it.Tara Kizer |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2006-10-06 : 01:13:09
|
You can also use traditional OSQL utility if you want to run it from command-line.Harsh AthalyeIndia."Nothing is Impossible" |
|
|
gsgill76
Posting Yak Master
137 Posts |
Posted - 2006-10-06 : 01:22:42
|
hey, I know about the OSQL utility, but how does it creates the full dataabse backup? or you write some sort of Stored Procedure?I shell be very thanksful if you send me(or tell me) the exact command to do the full backupRegards,Thanks.Gurpeet S. Gill |
|
|
Kristen
Test
22859 Posts |
Posted - 2006-10-06 : 01:28:49
|
Related thread: http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=73099 |
|
|
|
|
|