Subject Re: [ib-support] embedded SQL with gpre
Author Ann W. Harrison
At 10:36 AM 5/16/2001 +0200, Klaus-Dieter.Opitz@... wrote:

>I had wrote two functions with the same C-Code. I had preprocessed the
>C-Code with the Statement
>gpre -c <file>.e <file>.c -m -u <user> -p <password>
>All database handles and variables after that, are in the first
>function!!!!! Why?
>I want programming CONNECT, FETCH, DISCONNECT in every function with the
>same database.
>example:
>in function 1 connect employee.gdb, fetch the result from table1, disconnect
>in function 2 connect employee.gdb, fetch the result from table2, disconnect
>and so one.
>Is this a problem for Intebase?

No. The problem is that you need to set the scoping of the SET DATABASE
statement. Check the programmers guide. By default it is global. You
can set it to static or extern.


Regards,

Ann
www.ibphoenix.com
We have answers.