question

jkeri avatar image
jkeri asked

SQLCMD to upload a flat file to a database table

I need to use a BAT file to be launched form a WINDOWS SCHEDULED TASKS.

can i use SQLCMD in a BAT file to do the following?

1- connect to the database

2- load a CSV file to a database table. The columns are a 1-for-1 match between the file and the table

3- execute a SQL stored procedure

4- load a table into a flat file?

sqlcmd
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.