Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: DBI Failing to connect from cgi script

by peppiv (Curate)
on Mar 27, 2002 at 13:56 UTC ( #154663=note: print w/replies, xml ) Need Help??


in reply to DBI Failing to connect from cgi script

I'm running on FREEBSD with MySQL database. Our platforms may be way different, but here's a chunk of code that works for me. My sth is written a little differently.

my $sth = $dbh->prepare('SELECT * FROM applicants WHERE date_col += ? ORDER BY date_col, job_position'); $sth->execute($date) or die $sth->errstr; while (my @result = $sth->fetchrow_array()) { print qq(@result\n); }

peppiv

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (1)
As of 2021-06-19 09:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What does the "s" stand for in "perls"? (Whence perls)












    Results (91 votes). Check out past polls.

    Notices?