Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
This is the case. I need to do conditional reload. I have a table with last source database update date. This is one row table. i need the script to compare two dates - todays date and last database update date. If todays date =last update date i want the script to reload data, if not I want to exit script and save the appliaction with old data.
Any ideas?
Michael,
I worked it out.
instead of an exit script I just place a LOAD statement which references an unknown table. This causes an error which stops the reload without saving changes.
Cheers,
John.
-------------
LOAD
ROWCounted;
SQL SELECT COUNT(*) AS ROWCounted
FROM [HealthCentral].[dbo].[WaitingListHistory];
LET vRowCount = peek('ROWCounted',0);
IF $(vRowCount) < 44000000 THEN
LOAD x RESIDENT y;
END IF