Re: Getting Database Name
Posted in 1994
In article <T0g5qc2w165w@cssnet.sanford.nc.us>, david@cssnet.sanford.nc.us (J. David Schronce) wrote: > Is their any way to get the current active databse name from inside a 4GL > program in a RDS environment? I have a program that requires different > actions dependent on the current active database name. I have the > database name set as a unix environment variable. I guess if I can't > read it directly from inside informix, I could try to read it from > Unix... > > Any help with either would be GREATLY appreciated! Under 4.1 you could use fgl_getenv("DBNAME"), or you could use the routines in the FAQ Appendix A: IF open_flat("echo $DBNAME") THEN LET l_dbname = read_flat() END IF ------------------------------------------------ Kerry Sainsbury, kerry@kcbbs.gen.nz R&D Dude, Quanta Systems, Auckland, New Zealand ph. +64 9 377-4473 (work). +64 9 276-5546 (home) -------------------------------------------------