Lo all,
We have recently just moved the db from a socket connection
on the same machine to a port connection on another machine.
The network is a LAN.
I'm getting this error:
Unable to connect to database:DBI
connect('database=tm;host=mysqldb;port=3307','tm',...) failed: Lost
connection to
Reidy, Ron [mailto:[EMAIL PROTECTED] wrote:
Your statement only has one bind variable (?). The other bind
variable is actually a Perl variable. Your execute will fail because
of this.
However, there is another issue. You cannot substitute bind variables
in this manner. Your attempt to
Thanks guys!
I got it to work by using an array and dropping the \.
Ron,
I should have mentioned that I'm using MySQL, so I don't think SGA will
be an issue. I will keep your warning in mind though.
Thanks again all.
Steve
-Original Message-
From: Jonathan Leffler [mailto:[EMAIL
I have a couple forms for an in-house application. The user fills out
the fields and then submits which update a back end Oracle database.
I have looked for examples but can't really find anything.
How is it best to catch errors when doing DBI stuff in web applications?
Wrap the insert code
Resending because it's been several hours and I haven't seen this show up yet...
Hello all,
Sometimes it is just more sensible to find a workaround rather than a
solution.
So, here is an updated script that uses DBI::ADO to create the database,
DBI::ODBC
to populate and test it, and
In my case I would probably report and return. Easy enough to do for
what I am dong.
Robert
Reidy, Ron wrote:
I would definitely wrap the entire transaction in an eval {}. But, I'm
not sure if I would croak/die when a failure occurs vs. report the error
and go back.
rr
-Original
Hello all,
Sometimes it is just more sensible to find a workaround rather than a
solution. So,
here is an updated script that uses DBI::ADO to create the database, DBI::ODBC
to
populate and test it, and DBI::ADO to retrieve the pics via CGI.
Thanks for the pointer, Bart!
As before, the
Hi all,
I came across some funny behavior in Perl with the DBI package, and I
don't know how to explain it or why it is happening. I've tried
googling it, but haven't found anything yet. Here is the scenario:
I have some code that automatically tries to update a user's email
address if
Here's a guess, as I'm not familiar with your particular Database and DBD.
It looks like the DBD is treating your value as in integer. Perhaps the DBD
looks at the first part of the string, and thinks, here's a number, so I'll
pass an integer type to the database engine.
Suggestion: try
Hi Philip,
Yes, $dbh-{RaiseError} is set to 1. I have the code surrounded in
an eval that does a rollback if there is an error, or a commit if
there is no error. The code is committing and the query is being
executed, just not with the value I expect.
Thanks,
Dave
On Nov 10, 2006, at
Hi Brian,
Thanks for the suggestion. I thought that might be the case as well,
and I've already tried adding the type attribute as a varchar, but
there was no change.
Dave
On Nov 10, 2006, at 4:31 PM, CAMPBELL, BRIAN D (BRIAN) wrote:
Here's a guess, as I'm not familiar with your
FWIW, I tested a simple SELECT ? with your '[EMAIL PROTECTED]'
value against my Postgres 7.2 (DBD::Pg 1.21). It bound fine and
returned the correct value.
David Wu wrote:
Hi Brian,
Thanks for the suggestion. I thought that might be the case as well,
and I've already tried adding the type
12 matches
Mail list logo