Re: Quotes and apostrophes assistance
- From: rvtol+news@xxxxxxxxxxxx (Dr.Ruud)
- Date: Mon, 29 Oct 2007 22:05:53 +0100
"Beginner" schreef:
my ($rows) = $dbh->selectrow_array("SELECT foo FROM bar where
path=?",undef,q($name)) or die ....snip
Your q($name) creates the literal string $name.
my ($rows) =
$dbh->selectrow_array(
"SELECT foo FROM bar where path=?",
undef,
$name,
);
No need for die() if you set up the $dbh with 'RaiseError' on,
see perldoc DBI. Also look for 'trace'.
--
Affijn, Ruud
"Gewoon is een tijger."
.
- References:
- Quotes and apostrophes assistance
- From: Beginner
- Re: Quotes and apostrophes assistance
- From: Dr.Ruud
- Re: Quotes and apostrophes assistance
- From: Paul Lalli
- Re: Quotes and apostrophes assistance
- From: Beginner
- Quotes and apostrophes assistance
- Prev by Date: RE: array within array
- Next by Date: Re: Hash of array
- Previous by thread: Re: Quotes and apostrophes assistance
- Next by thread: SoapLite Error
- Index(es):
Relevant Pages
|