Requirement is for a simple Windows utility to run a (provided) SQL query against a Microsoft SQL Server database, and dump the resulting data to .csv
Utility will prompt the user for two things:
1) a date range – beginning and end dates, with the end date defaulting to 'yesterday'. Start date should load from xml config file, using the 'end date' from the previous time the utility was run
2) checkboxes for what departments to run the query against – '1000', '2000', etc up to '9000'. Default should be loaded from xml config file (user may select/deselect if needed)
When user clicks 'create' button, utility will connect to database and run the query, once for each department, and create a .csv for each execution. Query looks like:
SELECT somedata from TABLES
WHERE Field = Value
Where the final line indicates the department.
The results from each run are saved into the default location (stored in the config file) and named Export-Date-Department – eg: [url removed, login to view]
Utility should display message to indicate success, then save run date to config file and quit.
SQL Query will be provided to winning bidder along with sample results from that query.