Click here to Skip to main content
15,921,463 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I need to upload the xml file to the server at regular interval and update the sql database from that xml file. While uploading i need to be aware of copying the previous version of the xml file so that data is not lost in any case. I think we can upload the file at regular interval from scheduler in sql or there is some other best approach in MVC4. I can analyze the file status from file system watcher. The main concern is the best approach in the MVC4 for uploading the file after fixed interval of time and taking the backup.
Posted

Hello, consider to use MS SQL Integration Services[^]. For more informations please refer the following link:
Integration Services Tasks -> XML Task[^]
If you unable to use SSIS, consider to use CLR stored procedures or user defined functions to compose SQL Server jobs.
 
Share this answer
 
Use MS SQL Server Integration Services [SSIS]. It is very easy and does the work efficiently. If not you can do this with Windows Services.
Add a File watcher to watch a specific location
Once the file is available in the folder [File Watcher triggers an event],
rename the file by appending the datetime to the file.
You can then open it read the contents and move data to the table.

Regards,
Dinesh Kumar.V.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900