Re: Help me!Urgente!C funtion in informix 4GL!
Posted in 1999
On Thu, 11 Feb 1999, Sean P. Galvin wrote: > As you have said, yes you do have to do a stack of procedures. > > The reason behind this is you must follow Informix's method for passing > paramaters between 4gl and c. > > The reason for you procedures is that you are setting up the stack within > the 4gl environment prior to calling the C program. > > i do not know of any way of getting around this. > > Off the wall idea, use a stored procedure to call a c function. It's easier > however I cannot guarantee the performance. You can only call C functions from stored procedures if you have IDS/UDO (9.1x servers). > Milton Santos wrote in message <36C419C4.73EDABE1@usa.net>... > >I need documentation about how to use c function in informix - 4GL . > > > >Please don't tell me that this information is in the site of informix, i > >can found any documentation there,about this!!! The documentation is there. Go to: http://www.informix.com/answers. From there, choose the more documentation link, and follow your nose to the Informix-4GL section. The manual you should use is probably the Informix 4GL Reference Manual 6.0, which also applies to v7.2. The PDF file has the number 7611.pdf. The information you need is in Chapter 1 and Appendix C. > >Please help me!In Informix-4GL RDS,we can not call C function easyly, You have to have a custom runner with the C functions built into it. The functions can be the same as the functions you'd call from compiled I4GL, but you also have to produce an interface description file based on the template $INFORMIXDIR/etc/fgiusr.c. You simply link all these files into your runner with the cfglgo script. > >we need to do o stack of procedures! I'm not sure what you mean by this. If you mean you need to be able to call other C functions from within the functions called from your I4GL p-code, that is no problem. If you need to be able to call onto I4GL p-code functions from within your C functions, then you need to read the manual rather carefully, and you'll need to use the fglapi.h header. Given that you are embedding this code into a p-code runner, you won't need to worry about the fgl_start() or fgl_end() macros; they're used only if you write the main program in C and then need to call onto I4GL p-code functions. Yours, Jonathan Leffler (jleffler@informix.com) #include <wish/I/was/skiing.h> Guardian of DBD::Informix v0.60 (v0.61_02) -- http://www.perl.com/CPAN Informix IDN for D4GL & Linux -- http://www.informix.com/idn