Solved

Export Table structure SQL 2005

Posted on 2010-08-24
3
318 Views
Last Modified: 2012-05-10
I have a third party helping me design an application.  I would like to send them a copy of just the table structure from our accouting software's SQL 2005tables.  Is there a way to do so without backing up the data as well?

0
Comment
Question by:GSLElectric
  • 2
3 Comments
 
LVL 58

Expert Comment

by:cyberkiwi
ID: 33517402
In SSMS, expand Databases, <thedb>, Tables,
highlight the table you are after,
right-click, choose "Script table as", "create to", "Clipboard"
Paste into your email/document

Errata: this does not show any links to other tables, and is just the structure of one table.
0
 

Author Comment

by:GSLElectric
ID: 33517408
I'm wanting the structure for the entire database
0
 
LVL 58

Accepted Solution

by:
cyberkiwi earned 500 total points
ID: 33517422
All tables and objects:

Databases\<the db>
right-click, task, generate script
check: Script all objects in the selected database
Finish

Instead of all objects, you can instead use Next to enter the wizard and fine tune what you want exported.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Occasionally there is a need to clean table columns, especially if you have inherited legacy data. There are obviously many ways to accomplish that, including elaborate UPDATE queries with anywhere from one to numerous REPLACE functions (even within…
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

708 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

15 Experts available now in Live!

Get 1:1 Help Now