Hi -
I am trying out jOOQ (v2.2.2) against an Oracle 11.2.0.3 database API
that is heavily weighted towards pl/sql packages, views, and UDTs.
Previously I have used JPublisher to generate Java classes that can
call against this API. Using jOOQ - I am receiving compile errors in
the generated code. Is there a preferred method for reporting errors?
The DBAs that develop the database side like to overload their calls
to provide returned data in a variety of means. Here is one of the
errors I am encountering with Oracle package procedures. Here are 3
retrieve text calls in the package (note one is called
retrieve_text2).
/**
* Retrieve text from the database
*
* @param p_text The retrieved text
* @param p_id A text identifier of the text to retrieve
* @param p_office_id The office that owns the text. If not specified
or NULL, the session user's default office is used
*/
procedure retrieve_text(
p_text out clob, -- the text, unlimited
length
p_id in varchar2, -- identifier used to store
text (256 chars max)
p_office_id in varchar2 default null); -- office id, defaults
current user's office
/**
* Retrieve text from the database
*
* @param p_id A text identifier of the text to retrieve
* @param p_office_id The office that owns the text. If not specified
or NULL, the session user's default office is used
*
* @return The retrieved text
*/
function retrieve_text(
p_id in varchar2, -- identifier used to store
text (256 chars max)
p_office_id in varchar2 default null) -- office id, defaults
current user's office
return clob; -- the text, unlimited
length
/**
* Retrieve text and description from the database
*
* @param p_text The retrieved text
* @param p_description The retrieved description
* @param p_id A text identifier of the text to retrieve
* @param p_office_id The office that owns the text. If not
specified or NULL, the session user's default office is used
*/
procedure retrieve_text2(
p_text out clob, -- the text, unlimited
length
p_description out varchar2, -- the description
p_id in varchar2, -- identifier used to
store text (256 chars max)
p_office_id in varchar2 default null); -- office id, defaults
current user's office
jOOQ generates two methods with the same signature causing a compile
error.
/**
* Call CWMS_20.CWMS_TEXT.RETRIEVE_TEXT
*
* @param pId
* @param pOfficeId
* @throws org.jooq.exception.DataAccessException if something went
wrong executing the query
*/
public static java.lang.String retrieveText2(org.jooq.Configuration
configuration, java.lang.String pId, java.lang.String pOfficeId) {
usace.cwms.db.oracle.packages.cwms_text.RetrieveText2 f = new
usace.cwms.db.oracle.packages.cwms_text.RetrieveText2();
f.setPId(pId);
f.setPOfficeId(pOfficeId);
f.execute(configuration);
return f.getReturnValue();
}
/**
* Call CWMS_20.CWMS_TEXT.RETRIEVE_TEXT2
*
* @param pText OUT parameter
* @param pDescription OUT parameter
* @param pId IN parameter
* @param pOfficeId IN parameter
* @throws org.jooq.exception.DataAccessException if something went
wrong executing the query
*/
public static usace.cwms.db.oracle.packages.cwms_text.RetrieveText2
retrieveText2(org.jooq.Configuration configuration, java.lang.String
pId, java.lang.String pOfficeId) {
usace.cwms.db.oracle.packages.cwms_text.RetrieveText2 p = new
usace.cwms.db.oracle.packages.cwms_text.RetrieveText2();
p.setPId(pId);
p.setPOfficeId(pOfficeId);
p.execute(configuration);
return p;
}