[23996] in Perl-Users-Digest
Perl-Users Digest, Issue: 6197 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Mar 1 11:10:59 2004
Date: Mon, 1 Mar 2004 08:10:08 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Mon, 1 Mar 2004 Volume: 10 Number: 6197
Today's topics:
split into array <Mark.Fenbers@noaa.gov>
Re: split into array <noreply@gunnar.cc>
Re: split into array <kuujinbo@hotmail.com>
Re: split into array <tadmc@augustmail.com>
Re: split into array <noreply@gunnar.cc>
Re: split into array <tadmc@augustmail.com>
Re: split into array <noreply@gunnar.cc>
Statistics for comp.lang.perl.misc <gbacon@hiwaay.net>
Re: Win32::Process -- Inheriting IO::Socket Handles (..:: parizienne ::..)
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Mon, 01 Mar 2004 07:39:28 -0500
From: Mark J Fenbers <Mark.Fenbers@noaa.gov>
Subject: split into array
Message-Id: <40432F00.CF9DBC7E@noaa.gov>
This is a multi-part message in MIME format.
--------------71C10C2EEDEBC8FCD41B22DF
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
$myline = "0,1,2,3,4,,,,";
@myarray = split /,/, $myline;
print scalar @myarray; # prints 5
$myline = "0,1,2,3,4,,,,8";
@myarray = split /,/, $myline;
print scalar @myarray; # prints 9
In database output, sometimes the last field(s) in a record is(are) null, and so
the line looks like the first $myline. Other times, the last field is not null,
and so the line looks like the second $myline. Is there a way that I can get
Perl to report that scalar @myarray is 9 even if there are trailing null fields?
Mark
--------------71C10C2EEDEBC8FCD41B22DF
Content-Type: text/x-vcard; charset=us-ascii;
name="Mark.Fenbers.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Mark J Fenbers
Content-Disposition: attachment;
filename="Mark.Fenbers.vcf"
begin:vcard
n:Fenbers;Mark
tel;work:937-383-0430
x-mozilla-html:TRUE
org:National Weather Service;Ohio River Forecast Center
adr:;;;;;;
version:2.1
email;internet:Mark.Fenbers@noaa.gov
title:Sr. HAS Meteorologist
fn:Mark J Fenbers
end:vcard
--------------71C10C2EEDEBC8FCD41B22DF--
------------------------------
Date: Mon, 01 Mar 2004 14:12:19 +0100
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: split into array
Message-Id: <c1vd0a$1nam6n$1@ID-184292.news.uni-berlin.de>
Mark J Fenbers wrote:
> $myline = "0,1,2,3,4,,,,";
> @myarray = split /,/, $myline;
> print scalar @myarray; # prints 5
>
> $myline = "0,1,2,3,4,,,,8";
> @myarray = split /,/, $myline;
> print scalar @myarray; # prints 9
>
> In database output, sometimes the last field(s) in a record is(are)
> null, and so the line looks like the first $myline. Other times,
> the last field is not null, and so the line looks like the second
> $myline. Is there a way that I can get Perl to report that scalar
> @myarray is 9 even if there are trailing null fields?
As you show above, the split() function deletes empty trailing fields.
If you want to count all the fields, whether empty or not, why not do
it separately:
my $numfields = 1 + $myline =~ tr/,//;
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
------------------------------
Date: Mon, 01 Mar 2004 22:41:26 +0900
From: ko <kuujinbo@hotmail.com>
Subject: Re: split into array
Message-Id: <c1veia$7as$1@pin3.tky.plala.or.jp>
Mark J Fenbers wrote:
> $myline = "0,1,2,3,4,,,,";
> @myarray = split /,/, $myline;
> print scalar @myarray; # prints 5
>
> $myline = "0,1,2,3,4,,,,8";
> @myarray = split /,/, $myline;
> print scalar @myarray; # prints 9
>
> In database output, sometimes the last field(s) in a record is(are) null, and so
> the line looks like the first $myline. Other times, the last field is not null,
> and so the line looks like the second $myline. Is there a way that I can get
> Perl to report that scalar @myarray is 9 even if there are trailing null fields?
>
> Mark
my @myarray = split /(?=,)/, $myline;
'perldoc -f split' from your shell gives you the explanation - suggest
that you read it.
You might also want to look at the standard Text::ParseWords module. It
allows you parse CSV files and deal with fields that contain commas,
e.g. escaped using quotes and backslashes.
HTH - keith
------------------------------
Date: Mon, 1 Mar 2004 07:56:27 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: split into array
Message-Id: <slrnc46g8b.k62.tadmc@magna.augustmail.com>
Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
> Mark J Fenbers wrote:
>> @myarray = split /,/, $myline;
>> print scalar @myarray; # prints 5
> As you show above, the split() function deletes empty trailing fields.
It deletes trailing empty fields _by default_.
> If you want to count all the fields, whether empty or not,
Then don't let it default to the default. :-)
@myarray = split /,/, $myline, -1;
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Mon, 01 Mar 2004 15:29:18 +0100
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: split into array
Message-Id: <c1vhjj$1nmq6s$1@ID-184292.news.uni-berlin.de>
Tad McClellan wrote:
> Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
>> Mark J Fenbers wrote:
>>>
>>> @myarray = split /,/, $myline; print scalar @myarray;
>>> # prints 5
>>
>> As you show above, the split() function deletes empty trailing
>> fields.
>
> It deletes trailing empty fields _by default_.
>
>> If you want to count all the fields, whether empty or not,
>
> Then don't let it default to the default. :-)
>
> @myarray = split /,/, $myline, -1;
Thanks, Tad.
Actually, I looked in the docs for how to have it do something else
but the default, but didn't find it. Now I realize that this sentence
might be it: "If LIMIT is negative, it is treated as if an arbitrarily
large LIMIT had been specified." The meaning of that sentence wasn't
exactly obvious to me the first time I read it, and, to be honest, it
isn't now either.
What am I missing?
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
------------------------------
Date: Mon, 1 Mar 2004 08:52:14 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: split into array
Message-Id: <slrnc46jgu.k9c.tadmc@magna.augustmail.com>
Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
> Tad McClellan wrote:
>> Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
>>> Mark J Fenbers wrote:
>>>>
>>>> @myarray = split /,/, $myline; print scalar @myarray;
>>>> # prints 5
>>>
>>> As you show above, the split() function deletes empty trailing
>>> fields.
>>
>> It deletes trailing empty fields _by default_.
>>
>>> If you want to count all the fields, whether empty or not,
>>
>> Then don't let it default to the default. :-)
>>
>> @myarray = split /,/, $myline, -1;
>
> Thanks, Tad.
>
> Actually, I looked in the docs for how to have it do something else
> but the default, but didn't find it. Now I realize that this sentence
> might be it: "If LIMIT is negative, it is treated as if an arbitrarily
> large LIMIT had been specified." The meaning of that sentence wasn't
> exactly obvious to me the first time I read it, and, to be honest, it
> isn't now either.
>
> What am I missing?
The sentence before the one you quoted. :-)
If LIMIT is unspecified or zero, trailing null fields are stripped
So, if LIMIT is specified non-zero then trailing fields are not stripped.
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Mon, 01 Mar 2004 16:09:58 +0100
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: split into array
Message-Id: <c1vk1n$1oagi3$1@ID-184292.news.uni-berlin.de>
Tad McClellan wrote:
> Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
>> Tad McClellan wrote:
>>> Gunnar Hjalmarsson <noreply@gunnar.cc> wrote:
>>>> If you want to count all the fields, whether empty or not,
>>>
>>> Then don't let it default to the default. :-)
>>>
>>> @myarray = split /,/, $myline, -1;
>>
>> Thanks, Tad.
>>
>> Actually, I looked in the docs for how to have it do something
>> else but the default, but didn't find it. Now I realize that this
>> sentence might be it: "If LIMIT is negative, it is treated as if
>> an arbitrarily large LIMIT had been specified." The meaning of
>> that sentence wasn't exactly obvious to me the first time I read
>> it, and, to be honest, it isn't now either.
>>
>> What am I missing?
>
> The sentence before the one you quoted. :-)
>
> If LIMIT is unspecified or zero, trailing null fields are
> stripped
>
> So, if LIMIT is specified non-zero then trailing fields are not
> stripped.
Hmm.. Is it just me who don't find that to be the height of clearness?
I rather find it to border on an 'undisclosed feature'. :(
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
------------------------------
Date: Mon, 01 Mar 2004 14:20:43 -0000
From: Greg Bacon <gbacon@hiwaay.net>
Subject: Statistics for comp.lang.perl.misc
Message-Id: <1046hlramhrr7ef@corp.supernews.com>
Following is a summary of articles spanning a 7 day period,
beginning at 23 Feb 2004 14:34:43 GMT and ending at
01 Mar 2004 14:07:01 GMT.
Notes
=====
- A line in the body of a post is considered to be original if it
does *not* match the regular expression /^\s{0,3}(?:>|:|\S+>|\+\+)/.
- All text after the last cut line (/^-- $/) in the body is
considered to be the author's signature.
- The scanner prefers the Reply-To: header over the From: header
in determining the "real" email address and name.
- Original Content Rating (OCR) is the ratio of the original content
volume to the total body volume.
- Find the News-Scan distribution on the CPAN!
<URL:http://www.perl.com/CPAN/modules/by-module/News/>
- Please send all comments to Greg Bacon <gbacon@cs.uah.edu>.
- Copyright (c) 2004 Greg Bacon.
Verbatim copying and redistribution is permitted without royalty;
alteration is not permitted. Redistribution and/or use for any
commercial purpose is prohibited.
Excluded Posters
================
perlfaq-suggestions\@(?:.*\.)?perl\.com
faq\@(?:.*\.)?denver\.pm\.org
comdog\@panix\.com
Totals
======
Posters: 193
Articles: 708 (284 with cutlined signatures)
Threads: 146
Volume generated: 1378.2 kb
- headers: 642.1 kb (11,881 lines)
- bodies: 688.6 kb (22,293 lines)
- original: 402.0 kb (14,421 lines)
- signatures: 46.8 kb (1,097 lines)
Original Content Rating: 0.584
Averages
========
Posts per poster: 3.7
median: 2 posts
mode: 1 post - 88 posters
s: 12.9 posts
Posts per thread: 4.8
median: 4.0 posts
mode: 1 post - 32 threads
s: 5.1 posts
Message size: 1993.4 bytes
- header: 928.7 bytes (16.8 lines)
- body: 996.0 bytes (31.5 lines)
- original: 581.4 bytes (20.4 lines)
- signature: 67.7 bytes (1.5 lines)
Top 20 Posters by Number of Posts
=================================
(kb) (kb) (kb) (kb)
Posts Volume ( hdr/ body/ orig) Address
----- -------------------------- -------
44 113.6 ( 52.4/ 55.3/ 45.6) tadmc@augustmail.com
39 73.0 ( 29.3/ 43.6/ 19.8) Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
33 68.6 ( 30.2/ 30.1/ 11.2) Ben Morrow <usenet@morrow.me.uk>
33 58.4 ( 31.9/ 26.5/ 14.0) "gnari" <gnari@simnet.is>
26 35.9 ( 24.5/ 7.3/ 2.9) toylet <toylet_at_mail.hongkong.com>
21 43.5 ( 19.4/ 19.3/ 7.9) Uri Guttman <uri@stemsystems.com>
17 31.5 ( 16.9/ 13.5/ 6.0) Gunnar Hjalmarsson <noreply@gunnar.cc>
16 28.9 ( 15.8/ 13.1/ 6.7) "Matt Garrish" <matthew.garrish@sympatico.ca>
15 25.7 ( 13.8/ 9.8/ 5.0) Tore Aursand <tore@aursand.no>
14 36.9 ( 13.1/ 20.6/ 8.4) tassilo.parseval@post.rwth-aachen.de
13 24.2 ( 14.6/ 8.6/ 4.6) Beable van Polasm <beable+unsenet@beable.com.invalid>
11 18.7 ( 11.1/ 7.6/ 4.0) Cyde Weys <cyde@umd.edu>
11 19.1 ( 9.3/ 9.0/ 5.7) Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
11 21.0 ( 10.7/ 10.4/ 4.0) fifo <fifo@despammed.com>
10 30.8 ( 9.6/ 19.5/ 12.1) mgjv@tradingpost.com.au
10 16.1 ( 7.8/ 8.3/ 3.6) J Krugman <jill_krugman@yahoo.com>
9 14.0 ( 5.8/ 8.2/ 4.2) Malcolm Dew-Jones <yf110@vtn1.victoria.tc.ca>
9 21.1 ( 9.6/ 11.5/ 8.2) "Alan J. Flavell" <flavell@ph.gla.ac.uk>
9 13.2 ( 8.5/ 4.7/ 2.7) "Jürgen Exner" <jurgenex@hotmail.com>
8 18.1 ( 7.2/ 10.5/ 5.9) Brian McCauley <nobull@mail.com>
These posters accounted for 50.7% of all articles.
Top 20 Posters by Number of Followups
=====================================
(kb) (kb) (kb) (kb)
Followups Volume ( hdr/ body/ orig) Address
--------- -------------------------- -------
42 113.6 ( 52.4/ 55.3/ 45.6) tadmc@augustmail.com
39 73.0 ( 29.3/ 43.6/ 19.8) Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
33 68.6 ( 30.2/ 30.1/ 11.2) Ben Morrow <usenet@morrow.me.uk>
33 58.4 ( 31.9/ 26.5/ 14.0) "gnari" <gnari@simnet.is>
21 35.9 ( 24.5/ 7.3/ 2.9) toylet <toylet_at_mail.hongkong.com>
20 43.5 ( 19.4/ 19.3/ 7.9) Uri Guttman <uri@stemsystems.com>
17 31.5 ( 16.9/ 13.5/ 6.0) Gunnar Hjalmarsson <noreply@gunnar.cc>
16 28.9 ( 15.8/ 13.1/ 6.7) "Matt Garrish" <matthew.garrish@sympatico.ca>
15 25.7 ( 13.8/ 9.8/ 5.0) Tore Aursand <tore@aursand.no>
14 36.9 ( 13.1/ 20.6/ 8.4) tassilo.parseval@post.rwth-aachen.de
13 24.2 ( 14.6/ 8.6/ 4.6) Beable van Polasm <beable+unsenet@beable.com.invalid>
11 19.1 ( 9.3/ 9.0/ 5.7) Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
11 21.0 ( 10.7/ 10.4/ 4.0) fifo <fifo@despammed.com>
10 30.8 ( 9.6/ 19.5/ 12.1) mgjv@tradingpost.com.au
9 14.0 ( 5.8/ 8.2/ 4.2) Malcolm Dew-Jones <yf110@vtn1.victoria.tc.ca>
9 13.2 ( 8.5/ 4.7/ 2.7) "Jürgen Exner" <jurgenex@hotmail.com>
9 21.1 ( 9.6/ 11.5/ 8.2) "Alan J. Flavell" <flavell@ph.gla.ac.uk>
8 24.3 ( 11.1/ 11.0/ 6.0) jwillmore@adelphia.net
8 16.1 ( 7.8/ 8.3/ 3.6) J Krugman <jill_krugman@yahoo.com>
8 23.1 ( 6.5/ 15.1/ 13.0) Michele Dondi <bik.mido@tiscalinet.it>
These posters accounted for 58.6% of all followups.
Top 20 Posters by Volume
========================
(kb) (kb) (kb) (kb)
Volume ( hdr/ body/ orig) Posts Address
-------------------------- ----- -------
113.6 ( 52.4/ 55.3/ 45.6) 44 tadmc@augustmail.com
73.0 ( 29.3/ 43.6/ 19.8) 39 Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
68.6 ( 30.2/ 30.1/ 11.2) 33 Ben Morrow <usenet@morrow.me.uk>
58.4 ( 31.9/ 26.5/ 14.0) 33 "gnari" <gnari@simnet.is>
43.5 ( 19.4/ 19.3/ 7.9) 21 Uri Guttman <uri@stemsystems.com>
36.9 ( 13.1/ 20.6/ 8.4) 14 tassilo.parseval@post.rwth-aachen.de
35.9 ( 24.5/ 7.3/ 2.9) 26 toylet <toylet_at_mail.hongkong.com>
31.5 ( 16.9/ 13.5/ 6.0) 17 Gunnar Hjalmarsson <noreply@gunnar.cc>
30.8 ( 9.6/ 19.5/ 12.1) 10 mgjv@tradingpost.com.au
28.9 ( 15.8/ 13.1/ 6.7) 16 "Matt Garrish" <matthew.garrish@sympatico.ca>
25.7 ( 13.8/ 9.8/ 5.0) 15 Tore Aursand <tore@aursand.no>
24.3 ( 11.1/ 11.0/ 6.0) 8 jwillmore@adelphia.net
24.2 ( 14.6/ 8.6/ 4.6) 13 Beable van Polasm <beable+unsenet@beable.com.invalid>
24.1 ( 0.7/ 23.3/ 23.3) 1 "Stephen Strong" <copia@pacifier.com>
23.1 ( 6.5/ 15.1/ 13.0) 8 Michele Dondi <bik.mido@tiscalinet.it>
21.1 ( 9.6/ 11.5/ 8.2) 9 "Alan J. Flavell" <flavell@ph.gla.ac.uk>
21.0 ( 10.7/ 10.4/ 4.0) 11 fifo <fifo@despammed.com>
19.1 ( 9.3/ 9.0/ 5.7) 11 Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
18.7 ( 11.1/ 7.6/ 4.0) 11 Cyde Weys <cyde@umd.edu>
18.1 ( 7.2/ 10.5/ 5.9) 8 Brian McCauley <nobull@mail.com>
These posters accounted for 53.7% of the total volume.
Top 16 Posters by Volume of Original Content (min. ten posts)
=============================================================
(kb)
Posts orig Address
----- ----- -------
44 45.6 tadmc@augustmail.com
39 19.8 Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
33 14.0 "gnari" <gnari@simnet.is>
10 12.1 mgjv@tradingpost.com.au
33 11.2 Ben Morrow <usenet@morrow.me.uk>
14 8.4 tassilo.parseval@post.rwth-aachen.de
21 7.9 Uri Guttman <uri@stemsystems.com>
16 6.7 "Matt Garrish" <matthew.garrish@sympatico.ca>
17 6.0 Gunnar Hjalmarsson <noreply@gunnar.cc>
11 5.7 Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
15 5.0 Tore Aursand <tore@aursand.no>
13 4.6 Beable van Polasm <beable+unsenet@beable.com.invalid>
11 4.0 fifo <fifo@despammed.com>
11 4.0 Cyde Weys <cyde@umd.edu>
10 3.6 J Krugman <jill_krugman@yahoo.com>
26 2.9 toylet <toylet_at_mail.hongkong.com>
These posters accounted for 40.2% of the original volume.
Top 16 Posters by OCR (minimum of ten posts)
============================================
(kb) (kb)
OCR orig / body Posts Address
----- -------------- ----- -------
0.825 ( 45.6 / 55.3) 44 tadmc@augustmail.com
0.634 ( 5.7 / 9.0) 11 Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
0.620 ( 12.1 / 19.5) 10 mgjv@tradingpost.com.au
0.536 ( 4.6 / 8.6) 13 Beable van Polasm <beable+unsenet@beable.com.invalid>
0.529 ( 14.0 / 26.5) 33 "gnari" <gnari@simnet.is>
0.523 ( 4.0 / 7.6) 11 Cyde Weys <cyde@umd.edu>
0.512 ( 6.7 / 13.1) 16 "Matt Garrish" <matthew.garrish@sympatico.ca>
0.510 ( 5.0 / 9.8) 15 Tore Aursand <tore@aursand.no>
0.454 ( 19.8 / 43.6) 39 Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
0.446 ( 6.0 / 13.5) 17 Gunnar Hjalmarsson <noreply@gunnar.cc>
0.434 ( 3.6 / 8.3) 10 J Krugman <jill_krugman@yahoo.com>
0.407 ( 7.9 / 19.3) 21 Uri Guttman <uri@stemsystems.com>
0.407 ( 8.4 / 20.6) 14 tassilo.parseval@post.rwth-aachen.de
0.393 ( 2.9 / 7.3) 26 toylet <toylet_at_mail.hongkong.com>
0.385 ( 4.0 / 10.4) 11 fifo <fifo@despammed.com>
0.372 ( 11.2 / 30.1) 33 Ben Morrow <usenet@morrow.me.uk>
Bottom 16 Posters by OCR (minimum of ten posts)
===============================================
(kb) (kb)
OCR orig / body Posts Address
----- -------------- ----- -------
0.825 ( 45.6 / 55.3) 44 tadmc@augustmail.com
0.634 ( 5.7 / 9.0) 11 Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
0.620 ( 12.1 / 19.5) 10 mgjv@tradingpost.com.au
0.536 ( 4.6 / 8.6) 13 Beable van Polasm <beable+unsenet@beable.com.invalid>
0.529 ( 14.0 / 26.5) 33 "gnari" <gnari@simnet.is>
0.523 ( 4.0 / 7.6) 11 Cyde Weys <cyde@umd.edu>
0.512 ( 6.7 / 13.1) 16 "Matt Garrish" <matthew.garrish@sympatico.ca>
0.510 ( 5.0 / 9.8) 15 Tore Aursand <tore@aursand.no>
0.454 ( 19.8 / 43.6) 39 Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
0.446 ( 6.0 / 13.5) 17 Gunnar Hjalmarsson <noreply@gunnar.cc>
0.434 ( 3.6 / 8.3) 10 J Krugman <jill_krugman@yahoo.com>
0.407 ( 7.9 / 19.3) 21 Uri Guttman <uri@stemsystems.com>
0.407 ( 8.4 / 20.6) 14 tassilo.parseval@post.rwth-aachen.de
0.393 ( 2.9 / 7.3) 26 toylet <toylet_at_mail.hongkong.com>
0.385 ( 4.0 / 10.4) 11 fifo <fifo@despammed.com>
0.372 ( 11.2 / 30.1) 33 Ben Morrow <usenet@morrow.me.uk>
16 posters (8%) had at least ten posts.
Top 20 Threads by Number of Posts
=================================
Posts Subject
----- -------
35 dump the real string
34 finding common words
25 Comments requested: brief summary of Perl
16 EOL Anchor under Windows
15 Perl CGI.pm script executing differently on different systems
15 secure internet Perl programming for banking
15 regex
14 Splitting filenames to extract a string
13 return multiple arrays from functions
13 posix style regexp -> perl style regexp.
12 Test open ports
10 OOP
10 padr()
9 Regexp not working
9 Converting UTF-* characters to &#xxx;
9 Coderef usage in complex data structures
9 Perl complex data structure ... how to get more flexible access? how to avoid eval?
8 File Deletion Script Help
8 How to access filehandle through globref?
8 Why is Perl losing ground?
These threads accounted for 40.5% of all articles.
Top 20 Threads by Volume
========================
(kb) (kb) (kb) (kb)
Volume ( hdr/ body/ orig) Posts Subject
-------------------------- ----- -------
72.8 ( 33.3/ 36.7/ 16.0) 34 finding common words
57.9 ( 21.7/ 33.9/ 21.7) 25 Comments requested: brief summary of Perl
54.0 ( 35.3/ 15.2/ 6.5) 35 dump the real string
34.5 ( 2.1/ 32.3/ 32.3) 2 Posting Guidelines for comp.lang.perl.misc ($Revision: 1.5 $)
29.8 ( 17.0/ 12.3/ 5.6) 16 EOL Anchor under Windows
29.3 ( 12.3/ 16.2/ 6.9) 13 posix style regexp -> perl style regexp.
29.1 ( 7.2/ 21.2/ 11.8) 8 Why is Perl losing ground?
28.2 ( 15.1/ 12.7/ 6.6) 15 Perl CGI.pm script executing differently on different systems
27.8 ( 12.5/ 14.7/ 6.3) 14 Splitting filenames to extract a string
27.5 ( 3.0/ 24.3/ 23.7) 3 gd 1.41 install errors in red hat 9
26.8 ( 12.4/ 14.1/ 6.0) 15 secure internet Perl programming for banking
24.0 ( 7.6/ 15.6/ 8.1) 9 Perl complex data structure ... how to get more flexible access? how to avoid eval?
23.7 ( 11.9/ 10.5/ 5.8) 13 return multiple arrays from functions
23.4 ( 12.8/ 9.7/ 7.2) 15 regex
22.9 ( 8.9/ 12.0/ 7.4) 9 Converting UTF-* characters to &#xxx;
22.4 ( 8.1/ 13.6/ 7.6) 9 Coderef usage in complex data structures
20.8 ( 11.4/ 8.3/ 4.4) 12 Test open ports
17.4 ( 8.6/ 7.8/ 3.2) 10 OOP
17.0 ( 8.9/ 7.6/ 2.8) 8 File Deletion Script Help
17.0 ( 7.2/ 9.1/ 4.4) 8 [NEWBIE] Expanding a perl variable twice inside a substitution
These threads accounted for 44.0% of the total volume.
Top 13 Threads by OCR (minimum of ten posts)
============================================
(kb) (kb)
OCR orig / body Posts Subject
----- -------------- ----- -------
0.744 ( 7.2/ 9.7) 15 regex
0.639 ( 21.7/ 33.9) 25 Comments requested: brief summary of Perl
0.551 ( 5.8/ 10.5) 13 return multiple arrays from functions
0.528 ( 4.4/ 8.3) 12 Test open ports
0.520 ( 6.6/ 12.7) 15 Perl CGI.pm script executing differently on different systems
0.457 ( 5.6/ 12.3) 16 EOL Anchor under Windows
0.436 ( 16.0/ 36.7) 34 finding common words
0.430 ( 6.5/ 15.2) 35 dump the real string
0.430 ( 6.3/ 14.7) 14 Splitting filenames to extract a string
0.429 ( 1.9/ 4.4) 10 padr()
0.428 ( 6.0/ 14.1) 15 secure internet Perl programming for banking
0.423 ( 6.9/ 16.2) 13 posix style regexp -> perl style regexp.
0.414 ( 3.2/ 7.8) 10 OOP
Bottom 13 Threads by OCR (minimum of ten posts)
===============================================
(kb) (kb)
OCR orig / body Posts Subject
----- -------------- ----- -------
0.744 ( 7.2 / 9.7) 15 regex
0.639 ( 21.7 / 33.9) 25 Comments requested: brief summary of Perl
0.551 ( 5.8 / 10.5) 13 return multiple arrays from functions
0.528 ( 4.4 / 8.3) 12 Test open ports
0.520 ( 6.6 / 12.7) 15 Perl CGI.pm script executing differently on different systems
0.457 ( 5.6 / 12.3) 16 EOL Anchor under Windows
0.436 ( 16.0 / 36.7) 34 finding common words
0.430 ( 6.5 / 15.2) 35 dump the real string
0.430 ( 6.3 / 14.7) 14 Splitting filenames to extract a string
0.429 ( 1.9 / 4.4) 10 padr()
0.428 ( 6.0 / 14.1) 15 secure internet Perl programming for banking
0.423 ( 6.9 / 16.2) 13 posix style regexp -> perl style regexp.
0.414 ( 3.2 / 7.8) 10 OOP
13 threads (8%) had at least ten posts.
Top 8 Targets for Crossposts
============================
Articles Newsgroup
-------- ---------
18 alt.perl
14 comp.lang.awk
14 gnu.utils.help
14 comp.programming
3 comp.lang.python
3 comp.text.xml
1 comp.lang.php
1 comp.lang.perl.modules
Top 20 Crossposters
===================
Articles Address
-------- -------
15 "Arifi Koseoglu" <arifi@tnn.net>
7 "gnari" <gnari@simnet.is>
6 Jeff Schwab <jeffplus@comcast.net>
5 Gunnar Hjalmarsson <noreply@gunnar.cc>
3 claird@phaseit.net
3 cbfalconer@worldnet.att.net
3 "Jürgen Exner" <jurgenex@hotmail.com>
3 tadmc@augustmail.com
3 Ted Davis <tdavis@gearbox.maem.umr.edu>
2 Andy Dingley <dingbat@codesmiths.com>
2 "Robert Nilsson" <robert.nilsson@monet.no>
2 JC <jwcorpening@verizon.net>
2 Ben Morrow <usenet@morrow.me.uk>
2 "Matt Garrish" <matthew.garrish@sympatico.ca>
2 "Suresh Govindachar" <sgovindachar@yahoo.com>
1 Tore Aursand <tore@aursand.no>
1 Uri Guttman <uri@stemsystems.com>
1 Joe Smith <Joe.Smith@inwap.com>
1 "Randy Kobes" <randy@theoryx5.uwinnipeg.ca>
1 Malcolm Dew-Jones <yf110@vtn1.victoria.tc.ca>
------------------------------
Date: 1 Mar 2004 03:01:36 -0800
From: parizienne@parizienne.ch (..:: parizienne ::..)
Subject: Re: Win32::Process -- Inheriting IO::Socket Handles
Message-Id: <e45ae533.0403010301.6e7fd04a@posting.google.com>
George Kuetemeyer <george.kuetemeyer@mail.tju.edu> wrote in message
[...]
> I've created a TCP server using the IO::Socket documentation in the
> Perl IPC faq. It works like a charm, but is currently single-threaded.
> I want to try using Win32::Process to kick off a separate process for
> each connection (kind of like the Unix fork).
Heya all, same problem here... Could you help me please ? I wanna know
how to pass filehandles from perl to perl. I don't know if it is
possible...
Here is an outline of what I am doing :
1. Wait in while loop for client connection. Works fine. (same)
2. Accept a $client_handle connection handle. Works fine. (same)
3. I am waiting for tasks. The main perl creates Win32::Process
objects for each incoming task, specifying that the handles of calling
process are inherited (see below for a sample). The process runs, I/O
continues to happen in the main perl console (when using 'print'), but
I have an error when trying to send to socket. Could someone help me
please ?
[assuming that $remote is the socket (print $remote "Something\n";
works fine) and $tasknum the tasknumber =)]
Win32::Process::Create(
$ProcessObj,
"path_to\\perl.exe",
"perl.exe path_to\\test.pl $tasknum $remote",
1,
NORMAL_PRIORITY_CLASS,
".") || die "Couldn't create process!!\n";
******************************************
# test.pl
$tasknum = $ARGV[0];
$remote = $ARGV[1];
print "Hello\n";
print $remote "Hello\n";
Thanks in advance.
Sincerely yours
Dan
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V10 Issue 6197
***************************************