Could you be more precise? What do you mean by "quoted"? Is it apparently dropping values or something? qw// does not "quote" values for you in the way that $dbh->quote() does, for example. If you can give us some more context and explain what is being attempted, we can help you better.
Just to make sure I wasn't missing anything, though, I wrote a small code generator. This writes out a program that generates 1000 strings that get passed to an array. Run this, run the resulting program, and then examine the output file (out.txt). You'll see that all of the values were properly added to the array.
#!/usr/bin/perl -w
use strict;
open TEST, "> test.pl" or die $!;
my $string = "xxx " x 1000;
print TEST <<END_PERL;
#!/usr/bin/perl -w
use strict;
my \@string = qw/$string/;
open TEST, "> out.txt" or die \$!;
for (0..999){
print TEST "\$_ \$string[\$_]\\n";
}
close TEST;
Incidentally, if someone is trying to use qw// with over 900 items, I would suggest that there are better ways to handle this (such as writing that data to a file and reading it in later). It sounds like a design problem in the program may be contributing to the confusion.
Cheers,
Ovid
Join the Perlmonks Setiathome Group or just click on the the link and check out our stats. |