RE : DBI-connect does not work in crontab but works interactively

2004-12-14 Thread Duhaime Johanne
Thank you very much. That solves my problem -Message d'origine- De : Dan Nelson [mailto:[EMAIL PROTECTED] Envoyé : 13 décembre 2004 12:03 À : Duhaime Johanne Cc : [EMAIL PROTECTED] Objet : Re: DBI-connect does not work in crontab but works interactively In the last episode (Dec 13

DBI-connect does not work in crontab but works interactively

2004-12-14 Thread N. Kavithashree
hello, i have a shell script with 6 programs. if i run it directly as : sh first.sh all progrms with get executd and everything works fine. but if i give this script in crontab using 0 10 * * * /two/three/name.sh Only progs without database connection will get executed . but database

DBI-connect does not work in crontab but works interactively

2004-12-13 Thread Duhaime Johanne
53) open (DBLIST, $DB_LIST); #list of all db we have while (DBLIST) { my $db_name=$_; chomp($db_name); my $dsn = DBI:mysql:$db_name:localhost; # data source name my $dbh = DBI-connect ($dsn,$DBUSER, $DBPASS, { RaiseError = 1, PrintError = 0 }) or die Could

Re: DBI-connect does not work in crontab but works interactively

2004-12-13 Thread Dan Nelson
In the last episode (Dec 13), Duhaime Johanne said: I have a script that check the status of all innodb tables. It works fine interactively. But not from the crontab tab. Here is the error message and also a list of the environment variables from the crontab The message is about

Re: DBI-connect does not work in crontab but works interactively

2004-12-13 Thread Dan Nelson
In the last episode (Dec 13), Dan Nelson said: In the last episode (Dec 13), Duhaime Johanne said: I have a script that check the status of all innodb tables. It works fine interactively. But not from the crontab tab. Here is the error message and also a list of the environment

DBI Connect Fails after 20,000 record inserts/updates

2002-10-24 Thread Dallas Engelken
a new dbi connect and store it in the virus table (update if it's already there). Then I disconnect that dbi call. Continuing on, I take each entry and update the overall_stats table, based on the date the email was received.. So if I receive 100,00 emails on 10-24-2002, then instead of having

Re: DBI Connect Fails after 20,000 record inserts/updates

2002-10-24 Thread gerald_clark
for records older than 2 days (ie 600,000 records). I make a dbi connection and select all records older than 2 days. It returns the rows. Now I step through each row with a while loop, and if the entry is a virus, i open a new dbi connect and store it in the virus table (update if it's already

RE: DBI Connect Fails after 20,000 record inserts/updates

2002-10-24 Thread Dallas Engelken
24, 2002 10:32 AM To: [EMAIL PROTECTED] Subject: RE: DBI Connect Fails after 20,000 record inserts/updates Do you connect/disconnect before/after every insert? -Original Message- From: Dallas Engelken [mailto:dallase;nmgi.com] Sent: Thursday, October 24, 2002 9:52 AM To: [EMAIL

RE: DBI Connect Fails after 20,000 record inserts/updates

2002-10-24 Thread Artem Koltsov
Do you connect/disconnect before/after every insert? -Original Message- From: Dallas Engelken [mailto:dallase;nmgi.com] Sent: Thursday, October 24, 2002 9:52 AM To: [EMAIL PROTECTED] Subject: DBI Connect Fails after 20,000 record inserts/updates I am trying to parse an email log

DBI connect (help)

2002-05-15 Thread Taylor Lewick
Hi all, I am trying to connect to my mysql database with a perl script... I can connect from commnad line both passing a password or at password prompt... I can connect successfully with the following line in my script.. my $dbh = DBI-connect(DBI:mysql:database=mysql;host=localhost, root

mysql dbi connect

2001-08-18 Thread Steven Marx
I am having a problem with MySQL. I am seeking some advice on either what is wrong or how to pursue the cause of this bug. I am using Perl DBI to interface with MySQL and when i execute the following statement: $dbh = DBI-connect('DBI:mysql:database=dbmysql2', undef, undef, {PrintError =0

dbi-connect

2001-08-18 Thread Steven Marx
I am using Perl DBI to interface with MySQL and when i execute the following statement: $dbh = DBI-connect('DBI:mysql:database=dbmysql2', undef, undef, {PrintError =0}) || die $ DBI::errstr; it causes the error: [Fri Aug 17 09:59:50 2001] productioncontent14.pl: Access denied for user

Re: dbi-connect

2001-08-18 Thread Rich Duzenbury
Umm, you didn't specify a username or password...you instead passed 'undef'. This is the connect string I use: $dbh = DBI-connect( DBI:mysql:database=$pb_db; host=$pb_server; port=$pb_port, $pb_user, $pb_password

MySQL DBI connect

2001-08-17 Thread Steven Marx
I am having a problem with MySQL. I am seeking some advice on either what is wrong or how to pursue the cause of this bug. I am using Perl DBI to interface with MySQL and when i execute the following statement: $dbh = DBI-connect('DBI:mysql:database=dbmysql2', undef, undef, {PrintError =0

mysql dbi connect

2001-08-17 Thread Steven Marx
I am having a problem with MySQL. I am seeking some advice on either what is wrong or how to pursue the cause of this bug. I am using Perl DBI to interface with MySQL and when i execute the following statement: $dbh = DBI-connect('DBI:mysql:database=dbmysql2', undef, undef, {PrintError =0

DBI-connect

2001-06-26 Thread yann . carlier
how can I test DBI-connect ? I'm geting this error: Software error: Execution of /var/www/cgi-bin/mySQL.pl aborted due to compilation errors. Yann carlier +351-21-4527104/5 www.inteliware.net [EMAIL PROTECTED]

Re: DBI-connect

2001-06-26 Thread Sebastiaan J.A. Kamp
Looks like a perl script, so you can use 'or' (||) to evaluate your 'connect' string, i.e. To stop the script if connect fails use $dbh = DBI-connect(dbi:mysql:database:localhost,'user','password') || die No connection to database; To issue a warning only $dbh = DBI-connect

[Q] DBI connect with MySQL

2001-03-01 Thread wen
in/perl -w use strict; use CGI qw(:standard); use CGI::Carp; use DBI; CGI::use_named_parameters(1); my ($db); my $output = new CGI; $db = param('test') or die("Could not find database!"); my $dbh = DBI-connect("DBI:mysql:$db:$server",root,passward ); if (not $dbh) { p

Re: [Q] DBI connect with MySQL

2001-03-01 Thread ryc
die("Could not find database!"); my $dbh = DBI-connect("DBI:mysql:$db:$server",root,passward ); if (not $dbh) { print header, start_html('title'="Information on $host = $db", 'BGCOLOR'='white'); print END_OF_HTML; H1$host/h1 H2$db/h2

Re: [Q] DBI connect with MySQL

2001-03-01 Thread wen
iii You will get errors like these if your script does not print out a header iii before spitting out other information. It is usually best to print the iii header in the very beginning of the script so you do not have to worry about iii it. You dont have to wait until you are about to print out

Re: [Q] DBI connect with MySQL(SOLVED)

2001-03-01 Thread wen
Okay, I get it. The problem comes from the statement below, wen $db = param('test') or die("Could not find database!"); After I revised it to "my $db = "test" or die("Could not find database!");" I get expected result. Thanks for your consideration. Regards, --Wen [EMAIL PROTECTED]

Re: [Q] DBI connect with MySQL

2001-03-01 Thread Gerald L. Clark
aram('test') or die("Could not find database!"); my $dbh = DBI-connect("DBI:mysql:$db:$server",root,passward ); if (not $dbh) { print header, start_html('title'="Information on $host = $db", 'BGCOLOR'='white'); print END_OF_HTML; H1$host