How to create a where clause in ADF viewobject with bind variables when using DB2 database. (Doc ID 2164576.1)

Last updated on AUGUST 05, 2016

Applies to:

Oracle JDeveloper - Version 11.1.1.7.0 and later
Information in this document applies to any platform.

Symptoms

 ViewObject Where clause bind variable works fine with oracle Database connection but however the same where clause doesn't work with IBM DB2 database connection and throws below error.

[SQL0312] Variable Not Defined Or Not Usable. With A VO With A Bind Variable
oracle.jbo.jbotester.ErrorHandler$ExceptionWrapper: [SQL0312] Variable SEARCHCRITERIA not defined or not usable.
at oracle.jbo.jbotester.ErrorHandler.displayError(ErrorHandler.java:96)
at oracle.jbo.jbotester.ErrorHandler.displayError(ErrorHandler.java:89)
at oracle.jbo.jbotester.dialog.JTDialog.displayError(JTDialog.java:152)
at oracle.jbo.jbotester.dialog.VariableDialog.save(VariableDialog.java:176)
at oracle.jbo.jbotester.dialog.GenericDialog.actionPerformed(GenericDialog.java:227)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
at java.awt.Component.processMouseEvent(Component.java:6289)

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms