Toad Automation Designer - Set Variable action - cannot use expression

Hi all,

In a Set Variable action, I cannot seem to use an expression as ‘value’. In Toad for Data Analysts, you can use e.g.
and get the result of the expression into the value in a Set_Variable activity.

However, if you do that in Toad Automation Designer, the value becomes the select statement as a string. Reducing it just to the TO_CHAR() bit has a similar effect. I can’t get the result from the expression into the variable value. I can use a single system variable (e.g. %SYSDATE%), but other expressions don’t seem to work. Any thoughts?

I am having this same issue. Is this resolved somewhere?

These variables are not tied to a connection, but we do have several system variables that you can use (which don’t have to be set). One of them is DATETIME, which corresponds to the time on your PC. Go to Options -> Variables to see the rest.

If those don’t serve your needs, let us know what you are trying to accomplish and we’ll try to help.

Oh! You could use a Query Iterator action to set a variable from a database value.

I wrote a blog about here: