in reply to DBI conditional insert (and things of those nature)
Question 2: DBI-quote() is probably the best way Cool?my $sth = $dbh->prepare("select employee_number from employees where +employee_number = '$employee_number' for update"); $sth->execute; my $userID = ($sth->fetchrow)[0]; if ($userID) { print "This employee is already in there \n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: DBI conditional insert (and things of those nature)
by Hero Zzyzzx (Curate) on Jan 26, 2002 at 00:40 UTC | |
by dvergin (Monsignor) on Jan 26, 2002 at 01:25 UTC | |
by Hero Zzyzzx (Curate) on Jan 26, 2002 at 04:47 UTC | |
by impossiblerobot (Deacon) on Jan 26, 2002 at 01:19 UTC |