FAQ

Search Discussions

120 discussions - 683 posts

  • A while ago I asked for an example of a dispatch table. rkb@i.frys.com was kind enough to post the example below. After tinkering with it a while I think I got it working ok, but I wondered when you ...
    Harry PutnamHarry Putnam
    Apr 24, 2010 at 2:40 am
    May 6, 2010 at 11:00 pm
  • Why is it that the first two splits do not produce any elements? #!/usr/local/bin/perl use strict; use warnings; my $var = 100421; my @elems1 = split(/\d/,$var); my @elems2 = split(/./,$var); my ...
    Harry PutnamHarry Putnam
    Apr 11, 2010 at 3:40 pm
    Apr 13, 2010 at 7:13 am
  • Hi. I'm new to perl, and I stumbled across a strange behavior in my for loop. In the following code, the second for loop actually counts way passed what I expected, and actually stops at "yz" and not ...
    Magne SandøyMagne Sandøy
    Apr 13, 2010 at 3:36 am
    Apr 14, 2010 at 2:57 pm
  • Hi, The following line stores the first return value by the function Function1 to the variable $name: my ($name) = @_[0] = &Function1 ($arg); but this one doesn't work: my ($name) = $_[0] = ...
    Akhthar Parvez KAkhthar Parvez K
    Apr 29, 2010 at 11:31 am
    Apr 30, 2010 at 4:40 pm
  • I think this will work, but is it elegant.? If (condition){ if (nexted_condition){ do this. } Elsif (nexted_condition){ Do that... } else{ Do something else. } } else{ Do something else.. } Mimi
    Mimi CafeMimi Cafe
    Apr 13, 2010 at 11:36 pm
    Apr 15, 2010 at 6:26 pm
  • noob question" I see advanced users here using various styles of open(). (wrapping done by -ed) This: open( my $outfile, ' ', 'perlfile.txt') or die(" Error opening file:$!"); And this: open my ...
    Harry PutnamHarry Putnam
    Apr 6, 2010 at 4:14 am
    Apr 8, 2010 at 10:55 pm
  • Hi list, I am just wondering if I sumbled upon an error in perl an error in my logic or somehtign else see the below perl one liners $ perl -e '$n = 0.945; $r = sprintf("%.2f", $n); print "$r\n";' ...
    Rob CoopsRob Coops
    Apr 26, 2010 at 10:38 am
    Apr 29, 2010 at 7:37 am
  • I used MySQL substr function to extra 100 characters from the result of a query, but understandably, I don't get what I want. Now I looked at Perl's substr function and it doesn't look like it can ...
    Mimi CafeMimi Cafe
    Apr 18, 2010 at 1:34 pm
    Apr 18, 2010 at 10:43 pm
  • I need to do some matching of filenames in two top level directories. We expect to find a number of cases where the endnames ($_) are the same in both hierarchies but the full name is different. ...
    Harry PutnamHarry Putnam
    Apr 29, 2010 at 3:51 am
    Apr 30, 2010 at 2:09 am
  • Hi, I am having some problems making this little script work, it is supposed glob files from current dir, and add stuff at the top and bottom of such files. I am also unshure how the "autoflush" ...
    Abimael MartinezAbimael Martinez
    Apr 12, 2010 at 3:16 am
    Apr 12, 2010 at 3:54 pm
  • I'm having trouble getting a piece of data from a form input to print in html. Here's the relevant portion of my code sub subroutine { my($hash) = shift; my($data) = "$hash- {'expl'}"; print ...
    Chris CogginsChris Coggins
    Apr 12, 2010 at 8:48 am
    Apr 16, 2010 at 7:22 pm
  • Hello Perlers, this is probably going to be quick one. I know how to get an subroutine reference under "normal" circumstances, but I don't know how to get one from an object instance. Like: ---%<--- ...
    Eric Veith1Eric Veith1
    Apr 7, 2010 at 4:23 pm
    Apr 12, 2010 at 9:55 pm
  • Hello, I need help by using threads in combination with external packages (modules). At main script threads were created and within these threads an database-handler was defined. My Intention is to ...
    Frenzel, Joerg (ext)Frenzel, Joerg (ext)
    Apr 7, 2010 at 11:59 am
    Apr 8, 2010 at 8:09 am
  • Inside a here doc, how can I force an expression to be evaluated such as localtime: print <<"END"; `localtime time` Foo Bar END I know I can simply create the var before, my $var = localtime time; ...
    Joseph L. CasaleJoseph L. Casale
    Apr 30, 2010 at 4:27 pm
    Jun 2, 2010 at 8:12 am
  • Hi, When i am trying to install ExtUtils i have these errors are coming. I am trying ti install it in Mandriva. Can any one can give be the clue. Thanks in advance. *[root@localhost ...
    Raheel HassanRaheel Hassan
    Apr 22, 2010 at 11:21 am
    Apr 30, 2010 at 12:06 pm
  • Hello People, I am stuck on a minor problem. How can I create a hash? Data is as follow ---------- DATA ---------- # abc <-- this_should_be_hash_name {space} "random_name_or_number" "date" ...
    Raphael()Raphael()
    Apr 15, 2010 at 4:59 am
    Apr 16, 2010 at 9:19 am
  • [This message was inadvertently originally posted in a totally inappropriate group, so reposted here where it was supposed to have gone] Sorry that this is something of a ramble. I've been using perl ...
    Harry PutnamHarry Putnam
    Apr 6, 2010 at 3:57 pm
    Apr 12, 2010 at 3:07 pm
  • Patrick DuprePatrick Dupre
    Apr 7, 2010 at 5:44 pm
    Apr 8, 2010 at 5:46 pm
  • Hey all. I'm trying to make a perl script create some bat scripts to run some specific command and run a few at a time. If that makes any sense. Anyhow, say there are 20 files in a dir. Now these ...
    PaulPaul
    Apr 29, 2010 at 6:20 pm
    Apr 30, 2010 at 5:58 pm
  • Hi, Could someone explain this condition: Scenario: #1 unless ( (defined $result) && ($test !~ /TEST/) ) { my $result = "OK"; print "$result\n"; } I thought it was: UNLESS (IF NOT) $result is defined ...
    Akhthar Parvez KAkhthar Parvez K
    Apr 29, 2010 at 11:25 am
    Apr 30, 2010 at 1:53 am
  • Hello, I have a entry in my directory that is a soft-link to another directory. Is there a way in perl to get, starting from the link, the path of the real directory ? Thanks Andreas
    Andreas MoroderAndreas Moroder
    Apr 27, 2010 at 12:05 pm
    Apr 29, 2010 at 8:54 pm
  • Hi all, I used colorAllocateAlpha to specify a transparent color. After filling a circle with it, I don't see the background line which is drawn before. The code is pasted below. What did I do wrong ...
    CHAN, KENNETH 1 [AG/7721]CHAN, KENNETH 1 [AG/7721]
    Apr 22, 2010 at 9:12 am
    Apr 27, 2010 at 1:58 am
  • I've run into one of those things where I can't see why my code fails. ... and know it has to be something obvious. Why does the second usage of stat... fail in the find() funciton? ...
    Harry PutnamHarry Putnam
    Apr 21, 2010 at 11:30 pm
    Apr 22, 2010 at 3:23 pm
  • Hi all, I need to convert a lot of UNIX scripts into Perl. Most of them uses the UNIX's EOF/EOL functionality. These scripts are mostly used to connect to Oracle databases. At the moment, installing ...
    Newbie01 perlNewbie01 perl
    Apr 19, 2010 at 9:21 am
    Apr 22, 2010 at 4:31 am
  • Hi all, In one of my projects, I've written a test file t/22-upgrade.t. I have a test within this file that looks for an existing installation, checks the versions, and compares the configuration ...
    Steve BertrandSteve Bertrand
    Apr 15, 2010 at 10:50 pm
    Apr 17, 2010 at 7:28 pm
  • Hello, is it possible to get the acl entrie of a directory on linux with perl ? Thanks Andreas
    Andreas MoroderAndreas Moroder
    Apr 27, 2010 at 12:03 pm
    Jun 8, 2010 at 3:49 pm
  • #!/usr/bin/env perl use warnings; use strict; my $x= (1,2,3); print $x,"\n"; exit(0); ************************************* output: Useless use of a constant in void context at ./try.plx line 4. 3 ...
    SrdSrd
    Apr 20, 2010 at 2:59 pm
    Apr 21, 2010 at 5:01 pm
  • Hello all, I was helping a friend to install activeperl but encountered a weird error. The OS is Windows 7 with x64 chipset. I downloaded the ActivePerl 5.10 for x64 ( ...
    CHAN, KENNETH 1 [AG/7721]CHAN, KENNETH 1 [AG/7721]
    Apr 13, 2010 at 7:51 am
    Apr 15, 2010 at 10:53 am
  • Patrick DuprePatrick Dupre
    Apr 1, 2010 at 3:14 pm
    Apr 14, 2010 at 1:23 am
  • I would like to download all the modules (atleast important ones) from cpan website and keep them in my local disk rather going into www everytime. Can someone tell how to download all of them? Cheers
    Open SourceOpen Source
    Apr 9, 2010 at 2:19 pm
    Apr 10, 2010 at 1:15 pm
  • I have a test harness set up with a series of Selenium test scripts. Each script tests a specific scenario on my web site. But I have some scenarios that I want to test multiple times with different ...
    Bob McConnellBob McConnell
    Apr 6, 2010 at 3:54 pm
    Apr 9, 2010 at 8:13 pm
  • hi all, I've got a problem in following script: sub A { our %a; $a{"fred"} = 1; $a{"bella"} = 2; ... } sub B { if ($fred != $a{"fred"}) { print "fred failed.\n"; } if ($bella != $a{"bella"} { print ...
    Remy GuoRemy Guo
    Apr 29, 2010 at 8:30 am
    Apr 29, 2010 at 8:02 pm
  • I need to evaluate a statement in an if, elsif, else block, and the statement to evaluate in the elsif is too large as I need to run a SQL query and act on the return value. What would be a better ...
    Mimi CafeMimi Cafe
    Apr 21, 2010 at 3:56 am
    Apr 21, 2010 at 8:13 pm
  • I get following error when trying to open a session using Apache::Session::MySQL. Here is what I have 38 tie %session, " Apache::Session::MySQL", undef,{ 39 Handle = $dbh, 40 LockHandle = $dbh 41 }; ...
    Mimi CafeMimi Cafe
    Apr 18, 2010 at 11:15 pm
    Apr 19, 2010 at 11:16 pm
  • Hi,all: the "learning perl" say an array can have any number of elements,but when i run such codes: #!perl @abc=1..999999999999999999999999999999999; print @abc; it shows "range iterator outside ...
    XuboXubo
    Apr 13, 2010 at 9:43 am
    Apr 13, 2010 at 4:18 pm
  • Hi, I got this scrip that is suppsed to use the use the Getopt::Std; and GD::Graph::bars; to input generate an array from a file (age). With this array, the GD::Graph::bars is going to create a ...
    AlektoAlekto
    Apr 7, 2010 at 3:51 am
    Apr 11, 2010 at 3:32 pm
  • I get a page full of output from a command passed into a Net::Telnet session that as per the cpan example is stored in $output. I then want to call a sub passing $output into it, that matches a ...
    Joseph L. CasaleJoseph L. Casale
    Apr 11, 2010 at 3:10 am
    Apr 11, 2010 at 4:49 am
  • Hi all, I would like to read in a binary file and extract the 4-byte ints from it. Under Linux, something like "od -t uI". I got it working as follows: my $buffer = <STDIN ; my @buffer = split //, ...
    Raymond WanRaymond Wan
    Apr 8, 2010 at 5:30 am
    Apr 9, 2010 at 3:29 am
  • Hi all, We currently have OEM installed but will have to uninstall it due to Oracle Licensing issues. Customers do not want to pay for the performance and diagnostic pack and are actually considering ...
    Newbie01 perlNewbie01 perl
    Apr 6, 2010 at 11:47 am
    Apr 7, 2010 at 1:04 pm
  • Thanks to much help from the list, and hours of reading up on Unicode, the Encode module, and many posts to perlmonks, I've come up with a hideous solution for processing text files with different ...
    Doug CacialliDoug Cacialli
    Apr 3, 2010 at 7:49 pm
    Apr 7, 2010 at 8:41 am
  • Hey All, Wanted to know if Perl has any interactive shell (just like Python, Bash, Ruby etc have) by any chance. And if yes how do we invoke that. Cheers, Parag
    Parag KalraParag Kalra
    Apr 28, 2010 at 6:38 am
    May 2, 2010 at 12:55 am
  • Hello, I'm looking about how to work with $? returning from a system call. I have the following : system("echo 'DIS CHS(*)' | runmqsc SQFR | grep CHANNEL | sort | uniq -c"); print $?; which is ...
    Bruno CostacurtaBruno Costacurta
    Apr 22, 2010 at 12:04 pm
    Apr 26, 2010 at 2:56 pm
  • HI all, Does anyone know of any XML to text Perl script around that I can use? Basically, I have an XML file that is supposed to composed of fields and unfortunately on the server, I do not have a ...
    Newbie01 perlNewbie01 perl
    Apr 21, 2010 at 12:23 am
    Apr 26, 2010 at 7:00 am
  • Hi, This is embarrassing. All I want to do is read the content of a simple 10 line .txt file into an array and print out the lines, and I just can't seem to get it to work! /* $target = ...
    KrytenKryten
    Apr 21, 2010 at 8:04 pm
    Apr 22, 2010 at 8:01 pm
  • Hi, I wonder if some of you are in the same situation like me: I am the only Perl programmer in the company, at least trying hard to get along :-), but I have nobody to ask for help. So I spend hours ...
    HACKER NoraHACKER Nora
    Apr 22, 2010 at 9:39 am
    Apr 22, 2010 at 11:25 am
  • I am trying to match words or complete phrase (excluding special characters) like: 1. Tom 2. Tom and Jerry 3. Audio A4 Quattro I need to ensure users cannot feed my program with special characters so ...
    Mimi CafeMimi Cafe
    Apr 21, 2010 at 9:53 pm
    Apr 22, 2010 at 7:42 am
  • Hi all, I wanted to display the actual values in an array by the following simple codes: ********************************* use Class::Inspector; use Bio::Graphics; my @methods = Class::Inspector- ...
    CHAN, KENNETH 1 [AG/7721]CHAN, KENNETH 1 [AG/7721]
    Apr 13, 2010 at 7:34 am
    Apr 13, 2010 at 10:35 am
  • Is there a limit to the length of a string in perl? I'm combining about 200 pieces of data into a single string and writing the string to a file and am getting some weird behaviors every once in a ...
    Chris CogginsChris Coggins
    Apr 8, 2010 at 12:08 pm
    Apr 12, 2010 at 10:26 pm
  • Hi! I made this short script in order to see if there is posible to run "modified" unix commands from a Perl script. #!/usr/bin/perl use strict; use warnings; my $load = `uptime | awk '{print $8 $9 ...
    Niko zunaNiko zuna
    Apr 9, 2010 at 3:31 pm
    Apr 9, 2010 at 5:42 pm
  • Hi I am new in perl script. Does anyone know how to implement this puzzle in perl? [ 0 ] = 0 [ 1 ] = 1 [ 0, 1 ] = 1 [ 1, 1 ] = 2 [ 1, [ 1, 2 ] ] = -2 [ 1, 2, [ 8 ] ] = -5 [ 1, [ 2 ], [ 3 ] ] = -4 [ ...
    UbuntuUbuntu
    Apr 5, 2010 at 3:56 pm
    Apr 7, 2010 at 6:53 pm
Group Navigation
period‹ prev | Apr 2010 | next ›
Group Overview
groupbeginners @
categoriesperl
discussions120
posts683
users114
websiteperl.org

114 users for April 2010

Shlomi Fish: 63 posts Harry Putnam: 51 posts Shawn H Corey: 51 posts Uri Guttman: 45 posts John W. Krahn: 31 posts Thomas Bätzler: 25 posts Akhthar Parvez K: 24 posts Philip Potter: 18 posts Jim Gibson: 17 posts Mimi Cafe: 15 posts Brandon McCaig: 13 posts Rene Schickbauer: 13 posts Steve Bertrand: 13 posts C.DeRykus: 12 posts Newbie01 perl: 12 posts CHAN, KENNETH 1 [AG/7721]: 11 posts Rob Coops: 11 posts Owen: 10 posts Peter Scott: 10 posts Joseph L. Casale: 9 posts
show more
Archives