Excel as Database : Execute Non-Query : Update statement

Hi Frnds,
Excel_DataBaseConnection.zip (8.6 KB)

I am trying to execute a non-query on Excel connected as database, but the update query is not working on it.

can you please help me. Attd: Workflow


@Sarath Do u getting any error or it is not just updating the value?

Yes!. Please find the attached workflow it has the code and you can try running it.

@Sarath In Connection string Change “IMEX=1” value from 1 to 0 or -1, It will work.

if IMEX value is 1 can only do read operation on data in excel.
if IMEX value is 0 or -1 u can do read, write and update operation on data in excel.


Thanks a lot. It really works. I didn’t know the exact reason for all those parameters thanks for the explanation as well

1 Like

@Sarath For further information check below link.


@Sarath Ur welcome bro :grinning:

Hi, one more issue the Replace function is not working.

Query : "update [Sheet1$] set SN = Replace(SN,‘$#’,‘-’)”

Err Msg: Execute non query : Undefined function ‘Replace’ in expression.

do you have any idea whether this is a valid function.


@Sarath Is Replace function works in database operations in General?

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.