0 pts.
 OVRDBF in JAVA
I am trying to insert records to a member in a PF through JDBC. Tried with QCMDEXC in Java. But the member is not being overridden, inserting records in the First Member-always. What may bethe cause? Can any one suggest the possible solution for this?

Software/Hardware used:
ASKED: January 24, 2006  6:25 AM
UPDATED: November 25, 2009  2:08 AM

Answer Wiki:
Execute command OVRDBF MYFILE OTHERMBR where OTHERMBR is the one you wish to insert records into. Do this before doing anything with SQL. ========================================================== An ALIAS might be a good idea, but be aware that it creates a permanent (SQL) object. An OVRDBF might be needed, especially if the member name is variable. If creating SQL objects is not allowed, then OVRDBF is required. For the original question, exactly how was QCMDEXC invoked? It would need to be invoked as a stored proc if it was going to work at all. And what does the OVRDBF look like? Some parms might need changing. Tom
Last Wiki Answer Submitted:  November 25, 2009  2:08 am  by  Jay400   0 pts.
All Answer Wiki Contributors:  Jay400   0 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

Correction:
OVRDBF MYFILE MBR(OTHERMBR)

 0 pts.

 

I’m not confident that doing an override will work in a JDBC connection… Depending on how you connect to the system you may use one or more QZDASOINIT jobs, and if the override happens in 1 and the SQL executes in another, the override won’t work…
You may need to create an alias for the member using syntax such as:
CREATE ALIAS library/aliasname FOR library/file (member)
then use the alias in your jdbc statement…

 200 pts.