Automation - set value from sql statement

I'm attempting to use automation for the first time.

I'm setting 2 variables (which happen to be dates). Var 1 is today's date, var 2 is the max date from a table. After these are set, I compare them. If they are equal, execute a script, if they aren't equal, then pause the script.

My problem is that I can't seem to get the comparison to work. I'm getting an error that says "variable value is not valid 1/3/2012 12:00:00 AM = 0". The "1/3/2012 12:00:00 AM" is my "today" variable. For the "0", I'm assuming is the max date I mentioned previously.

When the execute the SQL statement used to set the max date var, it correctly returns the value I'm expecting but it does not appear to be doing that when I use it in the automation script.

I've attached some images showing how I'm setting this variable. Am I doing it correctly? What am I missing?

Hi,

I’m not sure if the automation_script.png shows your actual script. If so then did you notice you have validation errors (those two small exclamation signs at the upper right corner of if…else activity branches)? Click them and you’ll see what the error is.

If it’s not the point then I’ll need your Automation .tas script and the log file. Please set logging to Verbose first in the Setting activity. Log file is located in the Automation folder of the application data directory. To get application data directory click Help > About > Applicatioin Data directory. You can send those files directly to me (igor.manokhin@quest.com).

Thanks,

Igor.