Re: 4gl / c interface
Posted in 1995
Sanjay Kumar (SOHO!dpsanjay@whitestone.raileurope.com) wrote: : Is there a way for me to return multiple rows of data from an ESQL/C : function to a 4gl program. Sanjay, my solution to this problem is somewhat kludgy, but it has worked for me on numerous occasions: I create a temp table within the 4GL program for the rows to be returned. In the ESQL/C function, I INSERT the rows into that table, and if necessary, I RETURN the number of rows inserted to the 4GL program (or a negative error code). The 4GL program then SELECTs the rows from that temp table and drops it after use. The advantage of this approach is that the number of rows returned is practically unlimited, you are not necessarily bound by a static array of records. Hope this helps, Richard -- +----------------------------+-------------------------------------------+ | Dr. Richard Spitz | INTERNET: spitz@ana.med.uni-muenchen.de | | EDV-Gruppe Anaesthesie | Tel : +49-89-7095-3421 | | Klinikum Grosshadern | FAX : +49-89-7095-8886 | | 81366 Munich, Germany | | +----------------------------+-------------------------------------------+