how to get the warning message from DBI

2003-01-17 Thread limei zhang
Hi, there, I am using IMB DB2; DBD::DB2 driver ; perl program If I type a sql command on command line, eg db2 delete from table1 where col1 = a it will return a warning message as below if the record does not exist: SQL0100W No row was found for FETCH, UPDATE or DELETE; or the result of a

Re: List files

2003-01-09 Thread limei zhang
try this open (OUT, "ls -1 $target_dir/bin/$foo.*.dat|") || die "can not list the dir/file $!"; my @files = ; this will include $target_dir/bin/ and end line character, need process if necessary hope this is what you want. zlm - Original Message - From: "Don Mathews" <[EMAIL PROTECTED]>

Problem with set DB2_HOME environment variable during install DBD:DB2

2002-10-24 Thread Limei Zhang
Hi, there, I am using DB2 Runtime client (V7.2) on linux redhat 7.3. I am try to install DBD:DB2 (0.76)that I can run perl program to remote access database in the DB2 server. I have successfully install DBI. When I do Perl Makefile.PL It failed, and the error message is DB2_HOME environment v

Re: Problem with remotely connecting to db2 database using perl CGI

2002-10-18 Thread Limei Zhang
Thanks very much. I tried your suggestion and it works On 10/17/02 9:58 PM, "Swen Schillig" <[EMAIL PROTECTED]> wrote: > Michael > > Did you setup your DB2INSTANCE variable properly with > SetEnv DB2INSTANCE db2inst1 > in the httpd.conf file ? > Maybe the remote database belongs to another i

Problem with remotely connecting to db2 database using perl CGI

2002-10-18 Thread Limei Zhang
Hi, there, I am using DB2 UDB workgroup 7.2 on linux redhat 7.3, DBD-DB2 0.73 DBI 1.30 Perl 5. I have no problem to connect to database by runnig the perl program containing the following code in a command line: .. my $dbh = DBI->connect("dbi:DB2:$mydatabase", "$user", "$password"); . H

How to run db2 command in perl script

2002-10-16 Thread Limei Zhang
Hi, I am afraid this is a beginner's question. But I did not find in the web. I am using DB2 UDB workgroup 7.2 and DBI 0.73 and Perl 5. I intend to run some simple db2 command like "import" , how I can do it in perl? I tried to run it as a normal sql command: ### $stmt = "IMPORT FROM F