Hi,
I'd like to know if there is a way that I can generate a script with the
INSERT INTO instruction of the content of the table. I know how to generate
a script for the create table, drop the constraint, index, recreate the
table, constraint... but I need to have the content of the table into that
script. How can I do this? For the moment I do this by using a DTS that
generate a .txt file with the content of the table, and I add manualy the
INSERT INTO... instruction at the beginning of each row. A lost of time!
Thank you for your help.> I'd like to know if there is a way that I can generate a script with the
> INSERT INTO instruction of the content of the table.
http://www.aspfaq.com/5006 has a link to one such script.|||"Jacques Rhaume" <Jacques Rhaume@.discussions.microsoft.com> wrote in
message news:190EBD0A-275E-454A-851D-BF5083AD8D53@.microsoft.com...
> Hi,
> I'd like to know if there is a way that I can generate a script with the
> INSERT INTO instruction of the content of the table. I know how to
> generate
> a script for the create table, drop the constraint, index, recreate the
> table, constraint... but I need to have the content of the table into that
> script. How can I do this? For the moment I do this by using a DTS that
> generate a .txt file with the content of the table, and I add manualy the
> INSERT INTO... instruction at the beginning of each row. A lost of time!
> Thank you for your help.
http://vyaskn.tripod.com/code.htm#inserts
Try here.
Rick Sawtell
MCT, MCSD, MCDBA|||Not quite sure exactly what you are trying to do. You can generate create
and drop table scripts using QA, and right clicking on the table itself.
If you are just trying to get column names, try this:
Select column_name from
Information_Schema.columns where table_name = 'yourTable'
Archer
"Jacques Rhéaume" wrote:
> Hi,
> I'd like to know if there is a way that I can generate a script with the
> INSERT INTO instruction of the content of the table. I know how to genera
te
> a script for the create table, drop the constraint, index, recreate the
> table, constraint... but I need to have the content of the table into that
> script. How can I do this? For the moment I do this by using a DTS that
> generate a .txt file with the content of the table, and I add manualy the
> INSERT INTO... instruction at the beginning of each row. A lost of time!
> Thank you for your help.|||> Not quite sure exactly what you are trying to do. You can generate create
> and drop table scripts using QA, and right clicking on the table itself.
Jacques is also trying to script the data in the table.
No comments:
Post a Comment