Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

MySQL 5.1.11 Select Query

by bkiahg (Pilgrim)
on Aug 05, 2008 at 15:23 UTC ( [id://702393]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $query_submitted = "SELECT * FROM rates WHERE weight = 2"; # Hangs
    
    my $query_submitted = "SELECT * FROM rates WHERE zone2 = '4.67'"; # Wo
    +rks fine
    
  2. or download this
    my $weight = 4; 
    
    my $query_submitted = 'SELECT * FROM rates WHERE weight = ?';
    ...
    # This executes the query
    my $sth_submitted = $dbh->prepare($query_submitted) or die "Error prep
    +are";
    $sth_submitted->execute($weight) or die 'Error';
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (7)
As of 2024-04-24 10:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found