Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Script to Insert data
Message
From
12/11/2004 12:31:02
 
General information
Forum:
Microsoft SQL Server
Category:
Other
Miscellaneous
Thread ID:
00960451
Message ID:
00960924
Views:
37
Bless you and may your house be safe from tigers!

C.

>Hi Charles,
>
>There're tools, like Apex SQL Script (review at http://www.sql-server-performance.com/apex_sql_script_spotlight.asp), that you can use to script data. In simple case you can use script from http://www.nigelrivett.net/sp_CreateDataLoadScript.html
>
>>
>>So if I want to preserve my test data in table Table1 before I restore from a backup in which Table1 will be empty, I can create a database to hold the backup tables, create a table1 in database2 and fill it with test data copied from database1 as shown below ( assume I just prefix the tablename with the database name database1!table1 ?) And then after restoring backup for database1, reverse the process filling table in database1 from database2. Is that the best approach?
>>
>>Now, suppose I want to send my test data to a collegue? Would I just backup my database2 and send him that or is there a better way?
>>
>>( If I wanted to send a collegue a totally new table structure, or a change in structure, I would just create a script that Enterprise manager would generate for me. I guess I was hoping for a similar way to create a script with insert into statements based on existing data which I would send to someone else and they could run from QA and fill their table with this data. In VFP I would create a delimited file they could append from, but I'm still floundering on figuring out the SQLServer equivalent. )
>>
>>Appreciate your insights on this as you are fluent in both languages ( and, I suspect, many others <g> )
>>


Charles Hankey

Though a good deal is too strange to be believed, nothing is too strange to have happened.
- Thomas Hardy

Half the harm that is done in this world is due to people who want to feel important. They don't mean to do harm-- but the harm does not interest them. Or they do not see it, or they justify it because they are absorbed in the endless struggle to think well of themselves.

-- T. S. Eliot
Democracy is two wolves and a sheep voting on what to have for lunch.
Liberty is a well-armed sheep contesting the vote.
- Ben Franklin

Pardon him, Theodotus. He is a barbarian, and thinks that the customs of his tribe and island are the laws of nature.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform