Hi
welcome to uipath community
we can use EXECUTE QUERY activity
where in the property panel
–mention the connection string and ensure whether connection is made with TEST CONNECTION option in connection wizard
–then CommandType property mention as STORED PROCEDURE which willI nvoke
the procedure name specified in the SQL parameter.
–then SQL property mention the sql command and this field must be completed according to the selection from the CommandType property.
and finally mention the parameters with IN direction we want to pass with while in the sql command we can use that with @parametername
for more info on this. document from uipath would help you
Thank you for your reply.
The result of the stored proc I posted is this “2019-09-11 00:00:00.000”, it’s in row 1 and no Column name.
on my Execute SQL activity, I have below.
“usp_GetPreviousBusinessDate ‘ON’,'”+vCurrentDate+“‘’” . I assigned DateTime.Now.ToString(“yyyy-MM-dd”) to vCurrentDate.
Is this right? I can’t seem to get the result in UIPath. My DB connection is showing successful.
And how do I get the result to show in a message box and saved to a variable?
Sorry, I have very minimal coding knowledge but is given a tasked to run a task in UIPath and I am struggling . Any help is appreciated.
So the query window has the output in the properties and it stores the result in a DataTable, you can create it directly from the properties window by click “Ctrl+K”
Now once created add “output Data-Table” activity — It converts the result of the Data-Table to string!!!