Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
Log in  ::  Register  ::  Not logged in

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Script Table Data to Insert Statements

By Tatsu,

This script will create a series of insert statements for a given table. It does not support every single data type in every way and has some limitations. If you add any enhancements, please send them to me at so I can update it here. Update (28 Feb 2005): Added support/Fixed bug with smalldatetime type. Contributed by Bob Wiechman. Thanks Bob! Update (13 Dec 2005): Corrected support of uniqueidentifiers, added automatic identity detection, added filtering of output, added more detail in debug mode. Contributed by Richard Lesh. Thanks Richard!

Total article views: 4614 | Views in the last 30 days: 9
Related Articles

Ad hoc update to system catalogs is not supported.

Ad hoc update to system catalogs is not supported.


Ola Hallengren Updates Free Database Maintenance Scripts to Support SQLBackup 6.3

Ola Hallengren has recently updated his popular free SQL Server database maintenance scripts to su...


Foreign Language Support.

Foreign Language Support.


SQL Server 2012 AlwaysOn now officially supported by VMware

I read yesterday that VMware has updated the “Microsoft Clustering on VMware vSphere: Guidelines for...


Join the most active online SQL Server Community

SQL knowledge, delivered daily, free:

Email address:  

You make SSC a better place

As a member of SQLServerCentral, you get free access to loads of fresh content: thousands of articles and SQL scripts, a library of free eBooks, a weekly database news roundup, a great Q & A platform… And it’s our huge, buzzing community of SQL Server Professionals that makes it such a success.

Join us!

Steve Jones

Already a member? Jump in:

Email address:   Password:   Remember me: Forgotten your password?
Steve Jones