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.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 SSMS generate scripts

Author  Topic 

pssumesh2003
Starting Member

35 Posts

Posted - 2014-02-10 : 04:26:05
hi,

I am using Sql server 2005 . When I use generate script option in SSMS i could not able to find the Option to script Data ? Is there is options to script both schema and Data in ssms.? If it there , Please give the needful instructions

TG
Master Smack Fu Yak Hacker

6065 Posts

Posted - 2014-02-10 : 10:59:45
Sql Server's scripting is just for DDL. To move data you can "object explorer | right click the database | Export ..." or SSIS. But if you need to script the data you would need a custom tool or script.

Be One with the Optimizer
TG
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2014-02-10 : 18:55:46
SSMS can script data in SQL 2008, I don't think it was an option before then.

There are some scripts available which can do the task:

http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=73608
http://vyaskn.tripod.com/code.htm#inserts
Go to Top of Page

TG
Master Smack Fu Yak Hacker

6065 Posts

Posted - 2014-02-10 : 20:42:38
quote:
Originally posted by Kristen

SSMS can script data in SQL 2008

Cool - where is it? I don't see it.

Be One with the Optimizer
TG
Go to Top of Page

pssumesh2003
Starting Member

35 Posts

Posted - 2014-02-11 : 00:19:45
Thank You all .
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2014-02-11 : 03:15:52
quote:
Originally posted by TG

quote:
Originally posted by Kristen

SSMS can script data in SQL 2008

Cool - where is it? I don't see it.


Tasks : Generate Scripts : [Select database]

On "Choose Script Options : Table/View Options" select "Script Data" (which is FALSE by default)
Go to Top of Page

TG
Master Smack Fu Yak Hacker

6065 Posts

Posted - 2014-02-11 : 11:39:58
Awesome - Thanks!
Now I don't have to keep updating my ole 6.5 script every time a new datatype is introduced

Be One with the Optimizer
TG
Go to Top of Page
   

- Advertisement -