Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: undefined array use

by Fastolfe (Vicar)
on May 04, 2002 at 15:49 UTC ( [id://164008]=note: print w/replies, xml ) Need Help??


in reply to undefined array use

A side note: Since you're not making use of bind variables and are putting a variable directly into your SQL, be sure that you've sanitized $username. Don't let me put a single-quote in there and let me add arbitrary SQL to make your script do whatever I want. If you're basing this on DBI, a better approach might be something similar to this:
$sth = $dbh->prepare('select oid,* from timeclock where end_stamp is n +ull and username=?') or die "prepare: $DBI::errstr"; # for each username { $sth->execute($username) or die "execute: $DBI::errstr"; # now do whatever with $sth->fetchrow # }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://164008]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (2)
As of 2024-04-24 14:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found