C# Script to Build & Restore a Database Snapshot
$15-20 USD
Completed
Posted over 15 years ago
$15-20 USD
Paid on delivery
Hello, I have a demo website where anonymous users can edit test data. However I need to be able to reset the data every hour.
It's in a shared hosting environment, so I can't use Agents.
But I can have a scheduled tasks that visits an aspx page every hour.
So I need a 2 scripts in total:
1. The first looks at the database (SQL 2005) and builds an **sql or xml file containing all the values** for every record in a list of tables specified.
There will be about 10-20 tables. (if I can specify an arraylist of tables that would be good)
This can either be a C# asp.net web page or a console app. It will only be run once.
2. The next script must be an asp.net c# web form. This form must be able to restore the db based on the sql or xml output from the script above.
I want all the sql transactions as **UPDATES** and **not** INSERTS - because **I don't want to delete everything and create new records, just reset the data on the original records.**
notes:
* I use SubSonic - [login to view URL]
* framework: 3.5
* prefer c#
* asp.net 2.0
* CGI & PERL are **not** available on my server
## Deliverables
It has to work. It cannot time out.
So if it takes over 20 seconds to load it will not work