Monday, March 19, 2012

How can I make a script out of a table data ?

Hello,

I want to take a table (SQL server) and show all it's data in a form of INSERT... (text file)
so that I can show it on a web-page and just paste the INSERT text into aMyTableData.sql
and then I can just run this script on the Query analyzer and fill my table with data

I need it so I can backup my DATA both in English and other languages...
(a replacement for the DTS packages that gives me hard time with the LOCALE / UNICODE translation)

did anyone already made such program ?
where can I find something like this ?My initial thought is "Don't do it!"!

You are planning on having a textbox that the user will have complete control over, and then you are taking the contents of that textbox and turning it into a SQL script that will be run?

This is extremely insecure and could result in all sorts of malicious script being executed against your database. Even in a trusted intranet environment, I would not write such functionality.

My 2 cents.

Terri|||Here's an app that will do it in its Export feature: http://www.microsoft.com/downloads/details.aspx?FamilyId=F0D03472-5E6C-459E-A6D8-6745A729C3C9&displaylang=en

Terri, your concern is valid, but I'd assume (or at least hope) that the page on the site for doing this would be completely secure.|||

My advice is to use the following softwarehttp://www.denovations.com/products/sqlpopulator/ It's looks handy...

No comments:

Post a Comment