Hi,
I ran a simple Progress program with a temp table in it through the Proxygen as a non Persistent procedure. The temp table mirrors the SQL table. I retrieive the record from the SQL database in my Java program and do a println to make sure the record is available. It is.
I call the Progress program (App Server 10.2A) from the Java program and try to access the temp table and it goes Ka-boom, with the errror being: SQL Result Set not available. The error in the Progress program doesn't happen until I try the FIND FIRST on the temp table. Any suggestions ?
The Proxygen created class expects a SQL result set and that is exactly what I am sending it.
Code snippets:
Java:
System.
String com.tgw.push850datatotgw.mpFlatiAppservWeb850(ResultSet ttSqlPoHdr) throws Open4GLException, RunTime4GLException, SystemErrorException
Schema of input result set; Parameter 1 Field:headerid integer (java.lang.Integer) Field:fileid integer (java.lang.Integer) Field
onumber character (java.lang.String) Field
ostatus character (java.lang.String) Field
otype character (java.lang.String) Field
oacktype character (java.lang.String) Field
urposecode character (java.lang.String) Field:transportationmethod character (java.lang.String) Field:routing character (java.lang.String) Field:fob character (java.lang.String) Field:countryoforigin character (java.lang.String) Parameters: ttSqlPoHdr
I ran a simple Progress program with a temp table in it through the Proxygen as a non Persistent procedure. The temp table mirrors the SQL table. I retrieive the record from the SQL database in my Java program and do a println to make sure the record is available. It is.
I call the Progress program (App Server 10.2A) from the Java program and try to access the temp table and it goes Ka-boom, with the errror being: SQL Result Set not available. The error in the Progress program doesn't happen until I try the FIND FIRST on the temp table. Any suggestions ?
The Proxygen created class expects a SQL result set and that is exactly what I am sending it.
Code snippets:
Java:
ResultSet vrs_po_hdr = get_po_hdr_data(Connect_To_Map_DB, stmt, vfile_id);
// get first record
vrs_po_hdr.next();
// print out value to make sure record is there
vrs_po_hdr.next();
// print out value to make sure record is there
System.
out.println(vrs_po_hdr.getString("PONumber"));
//* Progress call
connecttgw.mpFlatiAppservWeb850(vrs_po_hdr);
connecttgw.mpFlatiAppservWeb850(vrs_po_hdr);
Proxy Gen:
String com.tgw.push850datatotgw.mpFlatiAppservWeb850(ResultSet ttSqlPoHdr) throws Open4GLException, RunTime4GLException, SystemErrorException
Schema of input result set; Parameter 1 Field:headerid integer (java.lang.Integer) Field:fileid integer (java.lang.Integer) Field
Progress:
DEF TEMP-TABLE tt-sql-po-hdr NO-UNDO
FIELD headerid AS INT
FIELD fileid AS INT
FIELD ponumber AS CHAR
FIELD postatus AS CHAR
FIELD potype AS CHAR
FIELD poacktype AS CHAR
FIELD purposecode AS CHAR
FIELD transportationmethod AS CHAR
FIELD routing AS CHAR
FIELD fob AS CHAR
FIELD countryoforigin AS CHAR
INDEX by-tt-sql-po-hdr
fileid
headerid.
FIELD headerid AS INT
FIELD fileid AS INT
FIELD ponumber AS CHAR
FIELD postatus AS CHAR
FIELD potype AS CHAR
FIELD poacktype AS CHAR
FIELD purposecode AS CHAR
FIELD transportationmethod AS CHAR
FIELD routing AS CHAR
FIELD fob AS CHAR
FIELD countryoforigin AS CHAR
INDEX by-tt-sql-po-hdr
fileid
headerid.
DEF INPUT PARAMETER TABLE FOR tt-sql-po-hdr .
OUTPUT TO "c:\temp\sql-po-hdr.txt".
PUT UNFORMATTED " hi there: " SKIP.
PUT UNFORMATTED " hi there: " SKIP.
/* error occurs on find first */
FIND FIRST tt-sql-po-hdr NO-LOCK NO-ERROR.
IF AVAIL tt-sql-po-hdr THEN
DISP tt-sql-po-hdr WITH FRAME dkdkdk WIDTH 300 DOWN.
FIND FIRST tt-sql-po-hdr NO-LOCK NO-ERROR.
IF AVAIL tt-sql-po-hdr THEN
DISP tt-sql-po-hdr WITH FRAME dkdkdk WIDTH 300 DOWN.
OUTPUT CLOSE.
Regards and thanks,
Rich