Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: For a better efficiency and speed question!

by Lotus1 (Vicar)
on Oct 04, 2011 at 15:35 UTC ( [id://929576]=note: print w/replies, xml ) Need Help??


in reply to For a better efficiency and speed question!

I am suspecting that the line my $control_num = join ( ',', ('?') x @control ); where I am joining all the control numbers from the array "@control" is slowing down the query results.

Why worry about speed when you code doesn't work?

use strict; use warnings; my @control = qw ( 1 2 3 4 5 6 7 ); my $control_num = join ( ',', ('?') x @control ); print "cn=$control_num<<\n"; __DATA__ cn=?,?,?,?,?,?,?<<

Replies are listed 'Best First'.
Re^2: For a better efficiency and speed question!
by Anonymous Monk on Oct 04, 2011 at 15:42 UTC
    I am sorry but it does work, the reason why you see "?" when you run your little test code is because the question marks are "place holders" in the SQL query.

Log In?
Username:
Password:

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

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

    No recent polls found