Pg module "eats" environment
Your name : Vitaly Piniygin
Your email address : <gambler@pfr.ru>
System Configuration
---------------------
Architecture:
Operating System:
Linux 2.2.9 i686 unknown
FreeBSD 3.2-RELEASE i386
PostgreSQL version: PostgreSQL-6.5.1
Compiler used (example: gcc 2.8.0):
linux:
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
fbsd:
gcc version 2.7.2.1
Please enter a FULL description of your problem:
------------------------------------------------
The Pg perl module seems to be broken in following way:
It "eats" environment after the database is opened and $0 perl variable is set
to some value ( see the script below).
Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
~ $ export | grep PG
declare -x PGDATABASE="test"
declare -x PGHOST="host"
declare -x PGLIB="/usr/local/pgsql/lib"
declare -x PGPASSWORD="passwd"
declare -x PGUSER="user"
~ $ perl -e 'use Pg; $dbconn = Pg::connectdb(""); $0 = "name";\
system("echo\$PGUSER:\$PGDATABASE");'
:
~/projects/TD/assist $
If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------
I'm a user, not perl-modules guru ;-)
----------------------------------
BG, Vit
E-Mail: Vitaly Piniygin <gambler@pfr.ru>
Date: 12-Oct-99
Time: 15:09:56
----------------------------------
Vitaly Piniygin wrote:
Your name : Vitaly Piniygin
Your email address : <gambler@pfr.ru>System Configuration
---------------------
Architecture:
Operating System:Linux 2.2.9 i686 unknown
FreeBSD 3.2-RELEASE i386
PostgreSQL version:
Compiler used (example: gcc 2.8.0):
linux:
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
fbsd:
gcc version 2.7.2.1Please enter a FULL description of your problem:
------------------------------------------------The Pg perl module seems to be broken in following way:
It "eats" environment after the database is opened and $0 perl variable is set
to some value ( see the script below).Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------~ $ export | grep PG
declare -x PGDATABASE="test"
declare -x PGHOST="host"
declare -x PGLIB="/usr/local/pgsql/lib"
declare -x PGPASSWORD="passwd"
declare -x PGUSER="user"
~ $ perl -e 'use Pg; $dbconn = Pg::connectdb(""); $0 = "name";\
system("echo\$PGUSER:\$PGDATABASE");'
:
~/projects/TD/assist $If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------I'm a user, not perl-modules guru ;-)
----------------------------------
BG, Vit
E-Mail: Vitaly Piniygin <gambler@pfr.ru>
Date: 12-Oct-99
Time: 15:09:56----------------------------------
************
this is on RH6.0 with PostgreSQL-6.5.2:
mergl@sls> export | grep PG
declare -x PGDATABASE="test"
declare -x PGHOST="host"
declare -x PGLIB="/usr/local/pgsql/lib"
declare -x PGPASSWORD="passwd"
declare -x PGPPATH="/home/mergl/pgp"
declare -x PGUSER="user"
mergl@sls> perl -e 'use Pg; $dbconn = Pg::connectdb(""); $0 = "name"; system("echo \$PGUSER:\$PGDATABASE");'
user:test
mergl@sls>
so it's not related to pgsql_perl5, it must be related to your environment.
Edmund
--
Edmund Mergl
mailto:E.Mergl@bawue.de
http://www.bawue.de/~mergl
Thanks for replay. It seems to be the 6.5.1-related bug,
since it was observed in two different boxes/OS's/environments, with the only
common part being postgres-6.5.1.
----------------------------------
BG, Vit
E-Mail: Vitaly Piniygin <gambler@pfr.ru>
Date: 13-Oct-99
Time: 11:33:33
----------------------------------
Show quoted text
On 12-Oct-99 Edmund Mergl wrote:
Vitaly Piniygin wrote:
Your name : Vitaly Piniygin
Your email address : <gambler@pfr.ru>System Configuration
---------------------
Architecture:
Operating System:Linux 2.2.9 i686 unknown
FreeBSD 3.2-RELEASE i386
PostgreSQL version:
Compiler used (example: gcc 2.8.0):
linux:
gcc version egcs-2.91.66 19990314/Linux (egcs-1.1.2 release)
fbsd:
gcc version 2.7.2.1Please enter a FULL description of your problem:
------------------------------------------------The Pg perl module seems to be broken in following way:
It "eats" environment after the database is opened and $0 perl variable is
set
to some value ( see the script below).Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------~ $ export | grep PG
declare -x PGDATABASE="test"
declare -x PGHOST="host"
declare -x PGLIB="/usr/local/pgsql/lib"
declare -x PGPASSWORD="passwd"
declare -x PGUSER="user"
~ $ perl -e 'use Pg; $dbconn = Pg::connectdb(""); $0 = "name";\
system("echo\$PGUSER:\$PGDATABASE");'
:
~/projects/TD/assist $If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------I'm a user, not perl-modules guru ;-)
----------------------------------
BG, Vit
E-Mail: Vitaly Piniygin <gambler@pfr.ru>
Date: 12-Oct-99
Time: 15:09:56----------------------------------
************
this is on RH6.0 with PostgreSQL-6.5.2:
mergl@sls> export | grep PG
declare -x PGDATABASE="test"
declare -x PGHOST="host"
declare -x PGLIB="/usr/local/pgsql/lib"
declare -x PGPASSWORD="passwd"
declare -x PGPPATH="/home/mergl/pgp"
declare -x PGUSER="user"
mergl@sls> perl -e 'use Pg; $dbconn = Pg::connectdb(""); $0 = "name";
system("echo \$PGUSER:\$PGDATABASE");'
user:test
mergl@sls>so it's not related to pgsql_perl5, it must be related to your environment.
Edmund