Unable to get result after executing SQL query using Data-SQL Server VBO

sumit

New Member
Hi

I am executing below update SQL query using Data-SQL Server VBO of blue prism but it is not updating the details in the database and also it is not throwing any error or exception .Please help me to fix this issue

update [TEST].[dbo].[student] set RollNo='xxxx',ID=xxx where DOB='xxxx'

Thanks,
Sumit Sharma
 

Sachin_Kharmale

Active Member
Hi @sumit,

SQL Update statement will not throw an error if the table record(Row) updated or not updated.
Make sure you are passing DOB value is present in Table.
In some cases the value we are passing which is not presents in table but SQL query executes successfully but 0 rows was affected in SQL Table. and we are not getting any exception.


I hope it will help you..!
 

sumit

New Member
Hi @sumit,

SQL Update statement will not throw an error if the table record(Row) updated or not updated.
Make sure you are passing DOB value is present in Table.
In some cases the value we are passing which is not presents in table but SQL query executes successfully but 0 rows was affected in SQL Table. and we are not getting any exception.


I hope it will help you..!
Yes you are correct but when i am executing it from the SQL management studio without blue prism it is updating the records in the table
while trying to execute it from blue prism it is not updating the records . Also for select query it is working fine and able to fetch the records from the same table.
 
Hi sumit.
SQL Management Studio may automatically COMMIT transactions.
So look at Begin and Commit transactions in your code. Either as actions in the VBO, or else in your SQL
 

bot1robot

Member
@sumit
Just a wild guess could you try removing inverted commas around rollNo filed. It seems , rollNo is numeric field and it is decorated with inverted comma. this could be possible cause of not updating record in actual table.
If still not resolved , can you try updating other table inside same database and same sql table (I mean just replace your sql query and update another table , rest as it is) and see how it goes.

Hope this helps.
 
Top