Rutherdale, Will wrote:
Louis, I'm sure the construct you give below has no effect in Perl.
"$someVariable" is identical to $someVariable.
Perhaps what you meant was
$arg1 = $dbh->quote( $someVariable ) . "::someText";
-Will
-----Original Message-----
From: Louis Gonzales [mailto:[EMAIL PROTECTED]
Sent: Thursday 23 February 2006 10:28
To: Christian Stalp
Cc: [email protected]; [EMAIL PROTECTED]
Subject: Re: Calling a PostgreSQL function via DBI
As for your select statement with the $arg1, ..., $argN, the
bind_param() function will work on those arguments too, I'd just suggest
to use the process of double quoting your string concatenation
assignments upfront:
$arg1 = "$someVariable" . "::someText";
- - - - - - - Appended by Scientific-Atlanta, Inc. - - - - - - -
This e-mail and any attachments may contain information which is confidential, proprietary, privileged or otherwise protected by law. The information is solely intended for the named addressee (or a person responsible for delivering it to the addressee). If you are not the intended recipient of this message, you are not authorized to read, print, retain, copy or disseminate this message or any part of it. If you have received this e-mail in error, please notify the sender immediately by return e-mail and delete it from your computer.
Will,
No, I meant exactly what I wrote. The quoting of the "$someVariable" in
string concatenation is a preference when using the binary "."
operator. The "" around the "$someVariable", strictly speaking do the
obvious interpolation. I don't think it's necessary to go down the
multitude of ways to write the string concatenation in PERL, which is
not the topic of this thread.
As for your suggestion of $dbh->quote(...) . "..."
if that works, GREAT, if you look further down the message, you'll see
that I address the 'properness' of the variables with bind_param() which
works beautifully with runtime parameter binding, to be used with the
"?"'s in the SQL statements.
In short, did you have a full example or suggestion for Christian? Or
did you want to discuss the multitude of ways to do the same thing?