From: Ron M. <mac...@gm...> - 2009-09-23 18:30:26
|
Thanks and I'll give that alternate syntax a try. I'm trying to recompile from CVS but it's failing. Could this be a problem with my config? Last few 'make' output lines: 4glc -s1 -V infx.4gl Compiling: infx.4gl to Translating to EC: infx.4gl Status : 11 Error compiling infx.4gl while executing 4glc -s1 -V infx.4gl Exit program.. 11 gmake[1]: *** [ifx_infx.ao] Error 11 gmake[1]: Leaving directory `/u/SOFTWARE/aubit4gl/aubit4glsrc/tools/asql' make: *** [corecompile] Error 2 On Wed, Sep 23, 2009 at 1:57 PM, Mike Aubury <mik...@au...> wrote: > Should be fixed now - FWIW - I normally do it a different way : > > > > main > define lv_tabname char(80) > define lv_id integer > > open session s2 to database im_ex > open session s1 to database test1 > > > use session s1 for > declare c1 cursor for select tabname from systables > > use session s1 for > foreach c1 into lv_tabname > > let lv_id=-1 > > use session s2 for > select tabid into lv_id from systables where tabname=lv_tabname > > if sqlca.sqlcode=100 then > display lv_tabname clipped," ",lv_id," missing" > else > display lv_tabname clipped," ",lv_id," has" > end if > > end foreach > > end main > > (FWIW - I needed to patch the esql/c version because switching the session > changed SQLCA.SQLCODE ! You might see something similar in the ODBC > driver...) > > > > > On Wednesday 23 September 2009 18:07:01 Ron MacNeil wrote: > > Hi, here I'm trying to open a second connection while using > > A4GL_SQLTYPE=unixodbc. It seems that from looking at the debug.out that > > A4GL is using an incorrect DSN name of 'duo_con2' while trying to open > the > > second connection; should it not be 'mssqltestserver' or am I using the > > 'connect' stmt incorrectly? > > > > I have also tried: > > connect to con2 as mssqltestserver #But here the DSN used is > > 'a4gl_000_mssqltest' > > > > ---- duo.4gl ---- > > database ifxtestserver > > #database mssqltestserver #<--This works > > > > # For ifxtestserver and mssqltestserver we have a table defined as: > > # CREATE TABLE atable (acolumn char(80)) > > main > > define me char(80) > > > > display 'hello' > > > > select acolumn into me from atable > > display me > > > > #database mssqltestserver #<--This works > > connect to mssqltestserver as con2 #<--This fails > > > > display 'hi' > > > > select acolumn into me from atable > > display me > > end main > > -- > Mike Aubury > > http://www.aubit.com/ > Aubit Computing Ltd is registered in England and Wales, Number: 3112827 > Registered Address : Clayton House,59 Piccadilly,Manchester,M1 2AQ > > > > > |