Hi
welcome to UiPath community
have we used any variables inside the sql statement here in UiPath
if so we need to mention it with @ in front like this @variablename
Hello! I have no variables inside the querry, just a parameter as an input of a condition, the name of the table i hard code it simple like :
“CREATE TABLE ROBOT_TABLE1 AS
Select distinct
t1.ID
FROM TABLE1 t1,
TABLE2 t2
WHERE t1.Data_id = :param
AND t1.JOB = t2.JOB
Union
Select…”
I tried to create a variable with the name of the table and introduce it with @variable_name, and give it the default value:“ROBOT_TABLE1”, but it didn’t work, it shows the same error. What can i do?
I came back with the solution !
You can format the string before with Assign where you put a variable that will take the string value of the query with the parameter you wanted in him. Important that the variable you use for the parameter role to not be used anywhere but there! (in my case, :param ) After you do that, use Replace activity to replace the “parameter” with the variable, implicitly the value that you want, and after that, use the string variable of formatted text in the Execute Non Query activity