Possible Duplicate:
How to execute an .SQL script file using c#
How would I programmatically run a SQL script that’s in a file on the local disk?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Answer taken from here How to execute an .SQL script file using c#
Put the command to execute the sql script into a batch file then run the below code
in the batch file write something like this (sample for sql server)