Re: searching database on emailaddress field

2006-01-31 Thread JupiterHost.Net
[EMAIL PROTECTED] wrote: Hi. Hello, Solved after I posted. Surround $email with 's. As in '$email'. Close, but this is a gun pointed at your head :) You either need to $dbh->quote() it or do the bind value/placeholder (see `perldoc DBI` for details of both)

AW: searching database on emailaddress field

2006-01-30 Thread Renee Backer
: Dienstag, 31. Januar 2006 04:23 An: dbi-users@perl.org Betreff: searching database on emailaddress field Hi. I'm trying to work out how to search a database by emailaddress. I'd like to see if an emailaddress exists in a database already. The code looks like this: /~

Re: searching database on emailaddress field

2006-01-30 Thread Ron Savage
On Tue, 31 Jan 2006 14:24:44 +1030, [EMAIL PROTECTED] wrote: Hi Luke > Solved after I posted. > Surround $email with 's. > As in '$email'. Nice try, but no cigar. See below. >> my $sth = $dbh->prepare("select id, address from subs_email where >> address=".$email); $sth->execute(); my @array = $

Re: searching database on emailaddress field

2006-01-30 Thread luke
Hi. Solved after I posted. Surround $email with 's. As in '$email'. Thanks. Kr. Luke. 31Jan2006 @ 13:52 [EMAIL PROTECTED] thusly spake > Hi. > > I'm trying to work out how to search a database by emailaddress. > I'd like to see if an emailaddress exists in a database already. > > The code look

searching database on emailaddress field

2006-01-30 Thread luke
Hi. I'm trying to work out how to search a database by emailaddress. I'd like to see if an emailaddress exists in a database already. The code looks like this: /~~~ my $email = '[EMAIL PROTECTED]'; my $sth = $dbh->prepare("select id, address from subs_email where address