Solved

How to get CREATE table script using TSQL

Posted on 2013-06-06
6
579 Views
Last Modified: 2013-07-02
I would like to get Create table scripts for given set of tables in my Database using TSQL. I know how to generate using SSMS > Table > Script table as > Create. But I would like to get the script using TSQL for an automated process. Please do assist.
0
Comment
Question by:Easwaran Paramasivam
  • 3
  • 2
6 Comments
 
LVL 10

Assisted Solution

by:rjanowsky
rjanowsky earned 500 total points
ID: 39228099
Have a look at this blog entry http://www.techrepublic.com/blog/datacenter/script-table-definitions-using-tsql/431. It might be of some help to you.
0
 
LVL 16

Author Comment

by:Easwaran Paramasivam
ID: 39253629
The script that you shared is not readable. Could you please provide the script in readable format?
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 39254088
Why don't you contact Tim Chapman directly for the script?
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 
LVL 10

Expert Comment

by:rjanowsky
ID: 39255239
Sorry, but it's not my script. Please contact Tim and ask for the plain sql script.
0
 
LVL 16

Accepted Solution

by:
Easwaran Paramasivam earned 0 total points
ID: 39280849
0
 
LVL 16

Author Closing Comment

by:Easwaran Paramasivam
ID: 39292521
Thanks.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

There have been several questions about Large Transaction Log Files in SQL Server 2008, and how to get rid of them when disk space has become critical. This article will explain how to disable full recovery and implement simple recovery that carries…
If you have heard of RFC822 date formats, they can be quite a challenge in SQL Server. RFC822 is an Internet standard format for email message headers, including all dates within those headers. The RFC822 protocols are available in detail at:   ht…
This video discusses moving either the default database or any database to a new volume.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now