Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
while (my $pointer = $sth->fetchrow_hashref){ $CT5 = $pointer->{'CT5'}; $STR = $pointer->{'STR'}; $FNAME = $pointer->{'FNAME'}; $LNAME = $pointer->{'LNAME'}; $EMAIL=$EMFNAME.$EMLNAME."\@tstcompany.com"; $EMAIL=~s/\s+//; $EMAIL=~s/\s+//; $EMAIL = lc($EMAIL); $sql="INSERT INTO email (f_name, l_name, code, ext, email) VALUES ('$FNAME', '$LNAME', '$STR', '$CT5', '$EMAIL')" +; #$sth = $dbh->prepare($sql); #$sth->execute() || die $sth->errstr; #$sth->finish; print "<br><b>EXT# = $CT5 / Code = $STR / First Name = $FNAME / Last N +ame = $LNAME / E-Mail = $EMAIL</b> "; } $sth = $dbh->prepare($sql); $sth->execute() || die $sth->errstr; $sth->finish;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: INSERT Problem
by matija (Priest) on Apr 28, 2004 at 18:47 UTC | |
|
Re: INSERT Problem
by b10m (Vicar) on Apr 28, 2004 at 18:50 UTC | |
by Anonymous Monk on Apr 28, 2004 at 19:50 UTC | |
by Sandy (Curate) on Apr 28, 2004 at 20:01 UTC | |
|
Re: INSERT Problem
by perlinux (Deacon) on Apr 29, 2004 at 08:06 UTC |