Hi There
I am not sure if Excel has this capability but i am attempting to create a Schedule Compliance Report where i need to take a Snapshot of data from a SQL Database on a particular Day of the Week and then do a Comparison a Week Later to see how that data has changed. Is this something that can be scheduled in Excel or would we require to have this data captured separately on individual weekly reports and then use Excel to do the comparison separately?
Regards
Vishal
Hi Vishal,
Welcome to our forum!
You could use Power Query to connect to the SQL database and get the data, but the Excel file must be open for the query to execute. You could write some VBA code in another file that is always open on your PC, that opens the file containing the query and refreshes it at set times.
You'd also need the VBA code to take a copy of the query output to capture the data at that point in time, so you can compare it next time the query refreshes.
I don't have any examples I can point you to though, sorry.
Mynda