I have a database with two tables. One of the tables was built using data from an Excel file (the tables are the same). I would like an executable file that I can schedule Windows to run at a set time each night that will replace the existing data in the SQL table with the new data from the Excel file. I don't know how to write an executable such as this, but was I'm hoping somebody else has already done something like this.
Here's what I have right now:
Excel file titled Website Contact List.xlsx
It's path is D:\DailyBatchJobs\Website Contact List.xlsx
The columns are, in order from left to right (these are the column headers also): FIRST_NAME, LAST_NAME, EMAIL, JOB_TITLE, PHONE, DIVISION_CODE, DIVISION_NAME (I have attached the file.)
The database is emailDB.mdf
The path for the database is: C:\inetpub\wwwroot\WebSite
I would like the script to replace the data in the table titled emailTbl.
The table has the following fields, in order from left to right:
id - this field is automatically incremented (primary key)
I'm working with SQL Express 2008.
Please let me know if I need to provide more information.