Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: For a better efficiency and speed question!

by Lotus1 (Deacon)
on Oct 04, 2011 at 15:35 UTC ( #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
Node Status?
node history
Node Type: note [id://929576]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (1)
As of 2016-07-30 08:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (265 votes). Check out past polls.