Avatar of Maliki Hassani
Maliki Hassani
Flag for United States of America asked on

VBA to Oracle replace routine issue

Experts,

I have a Excel VBA code that uploads data into a oracle table.  I want to pass a variable so it can do a find and replace.  I am getting an error when I use strSQL = "DELETE FROM QA_DAC where (TICKET_ID = TICKET_ID_VAR)". If I were to replace the TICKET_ID_VAR with a actual ticket ID it works fine.

The error that I am getting is a runtime error "TICKET_ID_VAR" : invalid identifier

Any suggestions on why it isn't passing?  I see that it is capturing the variable when I debug.

Attached
Routine-code.txt
Microsoft AccessMicrosoft ExcelSQL

Avatar of undefined
Last Comment
Maliki Hassani

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
mbizup

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Maliki Hassani

ASKER
Thank you!
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!
James Murphy