Problem Building SQL with Code

ShellWorker

Registered User.
Local time
Today, 16:45
Joined
Sep 23, 2008
Messages
12
I've built this SQL using VB:

INSERT INTO tblTemp2 (Contract) SELECT PHT_CONTR_NO FROM VB22.PRICHIST_TRUCK WHERE PHT_CONTR_NO = 'LPS790848';

When I execute it it returns the following Err.Description:

"SFHOFFM.TBLTEMP2" is an undefined name. SQLSTATE-42704

I can see that the issue is that I'm mixing a local table (tblTemp2 ) and a DB2 table (VB22.PRICHIST_TRUCK ) in my SQL statement. How can I stop it from prefexing my local table "tblTemp2" with my mainframe LogonID "SFHOFFM"?
 

Users who are viewing this thread

Back
Top Bottom