[22532] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 4753 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Mar 24 09:06:16 2003

Date: Mon, 24 Mar 2003 06:05:07 -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, 24 Mar 2003     Volume: 10 Number: 4753

Today's topics:
        "globbing" command line args on W2K? <edgue@web.de>
    Re: currency number to text conversion (Tad McClellan)
        Deep Recursion problem in Win32 clipboard.pm (Phil Hibbs)
    Re: Deep Recursion problem in Win32 clipboard.pm (Anno Siegel)
    Re: Deep Recursion problem in Win32 clipboard.pm <tassilo.parseval@rwth-aachen.de>
    Re: doubts on \n (Helgi Briem)
    Re: How to use Net::FTP - FTP Client class through a Fi (Joe Kamenar)
    Re: How to use Net::FTP - FTP Client class (Joe Kamenar)
    Re: Need help with regular expression (Anno Siegel)
    Re: Need help with regular expression <D'oh@a.deer>
    Re: Perl ODBC and SQL <somewhere@nowhere.com>
    Re: print here-documents question (M Browning)
    Re: print here-documents question <flavell@mail.cern.ch>
    Re: Really weird?!? (Anno Siegel)
        Statistics for comp.lang.perl.misc <gbacon@cs.uah.edu>
        update value in flat file <blnukem@hotmail.com>
    Re: update value in flat file (Anno Siegel)
    Re: update value in flat file <noreply@gunnar.cc>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Mon, 24 Mar 2003 14:52:57 +0100
From: Edwin Guenthner <edgue@web.de>
Subject: "globbing" command line args on W2K?
Message-Id: <3E7F0DB9.4090206@web.de>

Hi there,

I would like to start perl and to run with several
scripts, like

perl -MmyStuff xy*.pl

That would work on Unix; but not on Windows or OS/2:

Can't open perl script "xy*.pl": Invalid argument

I wrote some code in myStuff that would "glob" the
elements of @AGRV, so

perl -Mtvm::Base reallythere.pl xy*.pl

works now for me (assuming that reallythere.pl
is an existing script). Close, but not close enough.

Is there a simply way to do what I want to do?

[using bash or so is no option to me because
  my OS/2 environment is fixed and I would like
  something that works the same way on windows and on OS/2]



------------------------------

Date: Mon, 24 Mar 2003 06:20:49 -0600
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: currency number to text conversion
Message-Id: <slrnb7tu11.471.tadmc@magna.augustmail.com>

Michael Budash <mbudash@sonic.net> wrote:
> In article <3trfa.16086$pK4.1449944@newsread1.prod.itd.earthlink.net>,
>  "Jodyman" <Jodyman@hotmail.com> wrote:
>> "Mike" <earthtrip@gmx.net> wrote in message
>> news:b5l7d9$2aedu1$1@ID-161707.news.dfncis.de...
>> > Cameron wrote:

>> > > Has anyone run across a module that handles the conversion of currency
>> > > amounts - number to text string and visa versa. For example $500.00 ->
>> > > FIVE HUNDRED DOLLARS or FIVE HUNDRED DOLLARS -> $500.00.

> i've 
> performed an initial conversion of the VB code to perl,

> but i'd respectfully like to ask you folks to 
> critically review this V.01 code, looking for bugs, poor practices, etc.
> 
> sub NumToString {
> 
>    my $nNumber = shift;


I'd add some argument checking here:

   warn "NumToString: called with more than one argument\n" if @_;


>    my $NumToString;


You don't use this until much later, so it should be declared
much later (ie. right before its first use).


-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


------------------------------

Date: 24 Mar 2003 04:41:34 -0800
From: gg@snark.freeserve.co.uk (Phil Hibbs)
Subject: Deep Recursion problem in Win32 clipboard.pm
Message-Id: <a9ec249e.0303240441.25979546@posting.google.com>

gg@snark.freeserve.co.uk (Phil Hibbs) wrote in message news:<a9ec249e.0303140501.2d257005@posting.google.com>...
> I have a perl script that does this:
> 
> use Win32::Clipboard;
> my $CLIP = Win32::Clipboard();
> if ($CLIP->IsFiles()) {
>   $CLIP->Set($CLIP->GetFiles);
> } else {
>  $CLIP->Set($CLIP->GetText);
> }

I now have another problem with this script. I am using Perl on a
machine that doesn't have it installed locally, but there is an
installation on a network drive. When I run the script, I get the
following:

Deep recursion on subroutine "Win32::Clipboard::AUTOLOAD" at
I:\perl\site\5.00502\lib/Win32/Clipboard.pm line 26.

Here's the context:
__START__
package Win32::Clipboard;
#######################################################################
#
# Win32::Clipboard - Perl Module for Windows Clipboard Interaction
# ^^^^^^^^^^^^^^^^
# Version: 0.03 (23 Apr 1997)
#
#######################################################################

require Exporter;       # to export the constants to the main:: space
require DynaLoader;     # to dynuhlode the module.

@ISA = qw( Exporter DynaLoader );

#######################################################################
# This AUTOLOAD is used to 'autoload' constants from the constant()
# XS function.  If a constant is not found then control is passed
# to the AUTOLOAD in AutoLoader.
#

sub AUTOLOAD {
    my($constname);
    ($constname = $AUTOLOAD) =~ s/.*:://;
    #reset $! to zero to reset any current errors.
    $!=0;
    my $val = constant($constname, @_ ? $_[0] : 0); # LINE 26
    if ($! != 0) {
    
        # [dada] This results in an ugly Autoloader error

        #if ($! =~ /Invalid/) {
        #    $AutoLoader::AUTOLOAD = $AUTOLOAD;
        #    goto &AutoLoader::AUTOLOAD;
        #} else {

        # [dada] ... I prefer this one :)

            ($pack, $file, $line) = caller;
            undef $pack; # [dada] and get rid of 
                         # "used only once" warning...
            die "Win32::Clipboard::$constname is not defined, "
               ."used at $file line $line.";

        #}    
    }
    eval "sub $AUTOLOAD { $val }";
    goto &$AUTOLOAD;
}
__END__

Any ideas what the problem might be?

Phil Hibbs.


------------------------------

Date: 24 Mar 2003 13:02:49 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: Deep Recursion problem in Win32 clipboard.pm
Message-Id: <b5mvlp$4m4$3@mamenchi.zrz.TU-Berlin.DE>

Phil Hibbs <gg@snark.freeserve.co.uk> wrote in comp.lang.perl.misc:
> gg@snark.freeserve.co.uk (Phil Hibbs) wrote in message
> news:<a9ec249e.0303140501.2d257005@posting.google.com>...
> > I have a perl script that does this:
> > 
> > use Win32::Clipboard;
> > my $CLIP = Win32::Clipboard();
> > if ($CLIP->IsFiles()) {
> >   $CLIP->Set($CLIP->GetFiles);
> > } else {
> >  $CLIP->Set($CLIP->GetText);
> > }
> 
> I now have another problem with this script. I am using Perl on a
> machine that doesn't have it installed locally, but there is an
> installation on a network drive. When I run the script, I get the
> following:
> 
> Deep recursion on subroutine "Win32::Clipboard::AUTOLOAD" at
> I:\perl\site\5.00502\lib/Win32/Clipboard.pm line 26.
> 
> Here's the context:
> __START__
> package Win32::Clipboard;
> #######################################################################
> #
> # Win32::Clipboard - Perl Module for Windows Clipboard Interaction
> # ^^^^^^^^^^^^^^^^
> # Version: 0.03 (23 Apr 1997)
> #
> #######################################################################
> 
> require Exporter;       # to export the constants to the main:: space
> require DynaLoader;     # to dynuhlode the module.
> 
> @ISA = qw( Exporter DynaLoader );
> 
> #######################################################################
> # This AUTOLOAD is used to 'autoload' constants from the constant()
> # XS function.  If a constant is not found then control is passed
> # to the AUTOLOAD in AutoLoader.
> #
> 
> sub AUTOLOAD {
>     my($constname);
>     ($constname = $AUTOLOAD) =~ s/.*:://;
>     #reset $! to zero to reset any current errors.
>     $!=0;
>     my $val = constant($constname, @_ ? $_[0] : 0); # LINE 26
                ^^^^^^^^

Where is constant() defined?  If it isn't, you're calling an undefined
function from AUTOLOAD, which calls AUTOLOAD again... .  A recipe for
deep recursion.

[rest snipped]

Anno


------------------------------

Date: 24 Mar 2003 13:41:57 GMT
From: "Tassilo v. Parseval" <tassilo.parseval@rwth-aachen.de>
Subject: Re: Deep Recursion problem in Win32 clipboard.pm
Message-Id: <b5n1v5$r6r$1@nets3.rz.RWTH-Aachen.DE>

Also sprach Anno Siegel:

> Phil Hibbs <gg@snark.freeserve.co.uk> wrote in comp.lang.perl.misc:

>> Deep recursion on subroutine "Win32::Clipboard::AUTOLOAD" at
>> I:\perl\site\5.00502\lib/Win32/Clipboard.pm line 26.
>> 
>> Here's the context:
>> __START__
>> package Win32::Clipboard;
>> #######################################################################
>> #
>> # Win32::Clipboard - Perl Module for Windows Clipboard Interaction
>> # ^^^^^^^^^^^^^^^^
>> # Version: 0.03 (23 Apr 1997)
>> #
>> #######################################################################
>> 
>> require Exporter;       # to export the constants to the main:: space
>> require DynaLoader;     # to dynuhlode the module.
>> 
>> @ISA = qw( Exporter DynaLoader );

[...]

>> sub AUTOLOAD {
>>     my($constname);
>>     ($constname = $AUTOLOAD) =~ s/.*:://;
>>     #reset $! to zero to reset any current errors.
>>     $!=0;
>>     my $val = constant($constname, @_ ? $_[0] : 0); # LINE 26
>                 ^^^^^^^^
> 
> Where is constant() defined?  If it isn't, you're calling an undefined
> function from AUTOLOAD, which calls AUTOLOAD again... .  A recipe for
> deep recursion.

And in this case he has to reinstall the module since a missing
constant() functions suggests that the XS portion of the module either
isn't there or is not properly loaded by DynaLoader.

Tassilo
-- 
$_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
$_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval


------------------------------

Date: Mon, 24 Mar 2003 11:43:59 GMT
From: helgi@decode.is (Helgi Briem)
Subject: Re: doubts on \n
Message-Id: <3e7eee2c.3887570911@news.cis.dfn.de>

On Fri, 21 Mar 2003 20:42:14 -0500, Benjamin Goldberg
<goldbb2@earthlink.net> wrote:

>Every perl programmer who writes his perl programs on 
>Windows *doesn't* bang his head against the problem, 
>since the proper use of binmode() in the right places 
>will reduce or eliminate the problem completely.

Most programmers don't seem to know that they have to
do that as evidenced by the fact that this or related
issues are FAQs on almost every programmers newsgroup
or forum on the planet.

It is the lack of "the proper use of binmode" that is
usually the problem.

>Every C programmer who writes his C programs on Windows 
>*doesn't* bang his head against the problem, since proper 
>use of O_BINARY and O_TEXT (or "b" or "t", for stdio) in the 
>right places will reduce or eliminate the problem completely.

If the programmers knows this.  Again, very many don't.

I don't understand how you can say that "X is not a problem
because there are proper steps to take that will avoid or
solve X".  Of course there are, but many people don't know
them.  
-- 
Regards, Helgi Briem
helgi DOT briem AT decode DOT is


------------------------------

Date: 24 Mar 2003 06:01:08 -0800
From: joey19020@aol.com (Joe Kamenar)
Subject: Re: How to use Net::FTP - FTP Client class through a Firewall
Message-Id: <fca4c27e.0303240601.5de7e063@posting.google.com>

In order to get to the outside world, all traffic goes thtough a
firewall. If I use wsftp, I can specify the firewall info in the
set-up and everything works fine.

So, can this still be done with the FTP client in Perl?

- Joe


------------------------------

Date: 24 Mar 2003 06:04:27 -0800
From: joey19020@aol.com (Joe Kamenar)
Subject: Re: How to use Net::FTP - FTP Client class
Message-Id: <fca4c27e.0303240604.4a70d4ae@posting.google.com>

It is a firewall issue. How do I use this ftp class with an outbound
firewall? I have the proxy server name, my user ID and the password. I
can do this fine with wsftp, but not with the Perl class. What is the
way to get the firewall info in?

- Joe


------------------------------

Date: 24 Mar 2003 11:08:35 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: Need help with regular expression
Message-Id: <b5movj$322$1@mamenchi.zrz.TU-Berlin.DE>

D'oh  <D'oh@null.com> wrote in comp.lang.perl.misc:
> -=-=-=-=-=-
> 
> Hi,
> 
> I'm trying to create a script that will change 4 consecutive characters
> to a single character within a string.  Can someone enlighten me with a
> better solution to the one I've got?  Thanks.
> 
> #!/bin/perl
> use strict;
> use warnings;
> 
> my $string = "It SEEMS that the ''''CCCCAAAATTTT'''' sat on the
> mmmmaaaatttt";
> 
> $string =~ s/\'{4}/\'/g;
> for("A".."Z", "a".."z", "0".."9") {
>   $string =~ s/$_{4}/$_/g;
> }
> print("$string\n");  ## output: It SEEMS that the 'CAT' sat on the mat

Yes, use a backreference:

    s/(.)\1{3}/$1/g;

Use a suitable character class instead of "." to limit the effect.

Anno


------------------------------

Date: Mon, 24 Mar 2003 22:48:27 +1100
From: D'oh <D'oh@a.deer>
Subject: Re: Need help with regular expression
Message-Id: <3E7EF08B.291934@a.deer>

"Tassilo v. Parseval" wrote:
 
> You can use back-references:
> 
>     $string =~ s/(.)\1{3}/$1/g;
> 
> For such a squeezing-task I'd usually have recommended this idiom:
> 
>     $string =~ tr/A-Za-z'//s;
> 
> However, it also squeezes sequences of two characters so you can't use
> it here.
> 
> Tassilo
> --
> $_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
> pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
> $_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval

Thank you.  I appreciate it.


------------------------------

Date: Mon, 24 Mar 2003 11:17:58 -0000
From: "Bigus" <somewhere@nowhere.com>
Subject: Re: Perl ODBC and SQL
Message-Id: <b5mph7$11ku@newton.cc.rl.ac.uk>

Bob Walton wrote:
> Bigus wrote:
>
> ...
>> Using Win32::ODBC, I am sending a command to an M$ Access database
>> to match ... $db->Sql("SELECT * FROM userstable WHERE user =
>> '$nickname' ORDER BY thedate DESC");
>>
>> Now, the problem is that $username can contain ANY characters. There
>> are two
>
> nick------------------------^^^^?
>
>> that I have come across so far that are causing me problems:
>>
>> [XXX]Bill
>> James 'Jimmy' Hall
> ...
>
>> Is there some sort of "escaping" I can do in Perl that might solve
>> this, or any other remedy?
> ...
>
> That would be an SQL issue -- and every flavor of SQL has its own
> quoting method.  The best deal is to use the DBI module for your
> database work, coupled with DBD::ODBC.  You can still use your ODBC
> connection stuff.  In the DBI module, you can use the quote() method
> or use placeholders to take care of these issues automatically in a
> platform/database-transparent way.  If you want to do the quoting
> yourself, you'll need to read up on the various methods of quoting
> values in your flavor of SQL.  Good luck finding the docs with Access
> (they must have it in there *somewhere*).  And it looks like it varies
> with which version of Access you are using!

OK thanks.. That looks straight forward enough. That DBI module must be a
pretty complex piece of programming, so I hope it runs as quickly as
WIN32::ODBC. I'd still be interested in knowing how to do it with
WIN32::ODBC and MS Access tohugh - there must be a way, it's just finding
out! My news feed doesn't have any groups concerning Jet SQL. However, I
note the devguru site has a command reference section on Jet SQL, so maybe I
can email them for advice.

Regards
Bigus






------------------------------

Date: 24 Mar 2003 03:27:45 -0800
From: m.browning@plymouth.ac.uk (M Browning)
Subject: Re: print here-documents question
Message-Id: <eddc4731.0303240327.1f9ba68d@posting.google.com>

Bernard <bht@actrix.gen.nz> wrote in message news:<1fat7v0qrgnhouq2lsl5vk4d8f1dnlam1v@4ax.com>...
> Hi,
> 
> I am looking for a way to avoid escaping of HTM/JavaScript text in
> perl here-documents.
> 
> In other words I am not interested in the perl parser scanning the
> here-document for special characters e.g. backslash "\" and @.
> 
> The purpose of this is to cut and paste static text that works in the
> browser without having to alter it to keep perl happy. For me such
> alterations cause an undesired maintenance overhead.
> External .js files are not an option for performance reasons.
> 
> 

Pasting your HTML into a script for output is not generally considered
the solution to CGI delivery, as illustrated by the problems you are
having.  This is going to get a lot worse as your project scales.

Such issues are resolved by CGI.pm.  Read the documentation, it is not
very long.

Alternatively, the Template Toolkit (on CPAN) allows you to (among
loads of other things) maintain your HTML files entirely separately
from your business logic, have them edited by designers, and not worry
about multiple copies of mixed-content files.  Take a look.

[MB]


------------------------------

Date: Mon, 24 Mar 2003 13:42:37 +0100
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: print here-documents question
Message-Id: <Pine.LNX.4.53.0303241303120.4105@lxplus066.cern.ch>

On Mon, Mar 24, M Browning inscribed on the eternal scroll:

> Bernard <bht@actrix.gen.nz> wrote in message news:<1fat7v0qrgnhouq2lsl5vk4d8f1dnlam1v@4ax.com>...

> > The purpose of this is to cut and paste static text that works in the
> > browser without having to alter it to keep perl happy. For me such
> > alterations cause an undesired maintenance overhead.

> Pasting your HTML into a script for output is not generally considered
> the solution to CGI delivery, as illustrated by the problems you are
> having.  This is going to get a lot worse as your project scales.

That's good advice, and I wouldn't really advocate including reams
of HTML in a here document either, although it sometimes proves
convenient to include snippets of HTML within Perl code.

In which case, assuming there is nothing needing to be interpolated
into the HTML, the hon Usenaut shouldn't overlook the possibility of
using a single-quoted here-doc.

http://www.perldoc.com/perl5.8.0/pod/perlop.html#Quote-and-Quote-like-Operators

> Such issues are resolved by CGI.pm.

That's good advice in general; however, using CGI.pm's HTML-generating
features turns the hon Usenaut's problem into a different one, without
necessarily solving it AFAICS.

best regards


------------------------------

Date: 24 Mar 2003 11:45:22 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: Really weird?!?
Message-Id: <b5mr4i$4m4$1@mamenchi.zrz.TU-Berlin.DE>

Chris Lowth  <please@no.spam> wrote in comp.lang.perl.misc:
> Michael Budash wrote:
> 
> > In article <FHmfa.48$%l1.240@news13-win.server.ntlworld.com>,
> >  Chris Lowth <please@no.spam> wrote:
> >> Michael Budash wrote:
> >> > In article <nh6fa.7$v6.24796@newsfep2-gui>,
> >> >  Chris Lowth <please@no.spam> wrote:
> >> >> Ryan Ritten wrote:
> >> >> 
> >> >> > I don't get it... all I want is to check to see if the string $key
> >> >> > contains the string of characters represented by table$table!
> >> >> > 
> >> >> > so for example... if $table was equal to 4 .... it would check $key
> >> >> > and see if the string table4! was found within it... here is my
> >> >> > code:
> >> >> > 
> >> >> > 
> >> >> > print "key=$key\n";
> >> >> > print "table=$table\n";
> >> >> > if($key =~ /table$table!/)
                     ^            ^
[...]

> Correct! - and if you note, the posters original script was missing those 
> slashes which is why I suggested correcting the syntax in the first place. 

Hmmm...

Anno


------------------------------

Date: Mon, 24 Mar 2003 13:23:13 -0000
From: Greg Bacon <gbacon@cs.uah.edu>
Subject: Statistics for comp.lang.perl.misc
Message-Id: <v7u1m139qpcs42@corp.supernews.com>

Following is a summary of articles spanning a 7 day period,
beginning at 17 Mar 2003 13:25:02 GMT and ending at
24 Mar 2003 13:02:49 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) 2003 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:  226
Articles: 730 (295 with cutlined signatures)
Threads:  155
Volume generated: 1548.5 kb
    - headers:    639.4 kb (12,118 lines)
    - bodies:     870.6 kb (29,540 lines)
    - original:   514.7 kb (18,752 lines)
    - signatures: 37.9 kb (877 lines)

Original Content Rating: 0.591

Averages
========

Posts per poster: 3.2
    median: 2.0 posts
    mode:   1 post - 109 posters
    s:      9.1 posts
Posts per thread: 4.7
    median: 3 posts
    mode:   1 post - 30 threads
    s:      4.4 posts
Message size: 2172.1 bytes
    - header:     896.9 bytes (16.6 lines)
    - body:       1221.2 bytes (40.5 lines)
    - original:   722.0 bytes (25.7 lines)
    - signature:  53.1 bytes (1.2 lines)

Top 10 Posters by Number of Posts
=================================

         (kb)   (kb)  (kb)  (kb)
Posts  Volume (  hdr/ body/ orig)  Address
-----  --------------------------  -------

   38    70.2 ( 29.1/ 41.1/ 14.1)  Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
   38    83.8 ( 32.3/ 45.1/ 19.2)  Benjamin Goldberg <goldbb2@earthlink.net>
   32    98.1 ( 35.3/ 58.6/ 46.9)  tadmc@augustmail.com
   18    50.1 ( 16.1/ 33.9/ 10.6)  Michael Budash <mbudash@sonic.net>
   17    37.7 ( 15.8/ 19.4/  5.0)  Chris Lowth <please@no.spam>
   16    38.5 ( 15.2/ 19.7/ 11.4)  tassilo.parseval@post.rwth-aachen.de
   15    22.7 ( 13.5/  9.2/  4.4)  "Jürgen Exner" <jurgenex@hotmail.com>
   13    28.8 ( 12.7/ 14.1/ 12.5)  abigail@abigail.nl
   11    15.9 (  9.6/  6.0/  3.4)  "Tore Aursand" <tore@aursand.no>
   11    17.5 (  9.9/  6.9/  3.6)  Gunnar Hjalmarsson <noreply@gunnar.cc>

These posters accounted for 28.6% of all articles.

Top 10 Posters by Volume
========================

  (kb)   (kb)  (kb)  (kb)
Volume (  hdr/ body/ orig)  Posts  Address
--------------------------  -----  -------

  98.1 ( 35.3/ 58.6/ 46.9)     32  tadmc@augustmail.com
  83.8 ( 32.3/ 45.1/ 19.2)     38  Benjamin Goldberg <goldbb2@earthlink.net>
  70.2 ( 29.1/ 41.1/ 14.1)     38  Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
  50.1 ( 16.1/ 33.9/ 10.6)     18  Michael Budash <mbudash@sonic.net>
  46.5 (  0.6/ 45.9/ 45.3)      1  Neil C <neilc252@yahoo.com>
  38.5 ( 15.2/ 19.7/ 11.4)     16  tassilo.parseval@post.rwth-aachen.de
  37.7 ( 15.8/ 19.4/  5.0)     17  Chris Lowth <please@no.spam>
  28.8 ( 12.7/ 14.1/ 12.5)     13  abigail@abigail.nl
  22.7 ( 13.5/  9.2/  4.4)     15  "Jürgen Exner" <jurgenex@hotmail.com>
  20.5 (  6.8/ 13.8/  7.9)      9  david <dwlepage@yahoo.com>

These posters accounted for 32.1% of the total volume.

Top 10 Posters by Volume of Original Content (min. five posts)
==============================================================

        (kb)
Posts   orig  Address
-----  -----  -------

   32   46.9  tadmc@augustmail.com
   38   19.2  Benjamin Goldberg <goldbb2@earthlink.net>
   38   14.1  Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
   13   12.5  abigail@abigail.nl
   16   11.4  tassilo.parseval@post.rwth-aachen.de
   18   10.6  Michael Budash <mbudash@sonic.net>
    8    9.2  AK <aknntp@yahoo.com>
    9    7.9  david <dwlepage@yahoo.com>
    6    5.9  bwalton@rochester.rr.com
    9    5.6  Stephan Bour <sbour@niaid.nih.gov>

These posters accounted for 27.8% of the original volume.

Top 10 Posters by OCR (minimum of five posts)
==============================================

         (kb)    (kb)
OCR      orig /  body  Posts  Address
-----  --------------  -----  -------

0.885  ( 12.5 / 14.1)     13  abigail@abigail.nl
0.800  ( 46.9 / 58.6)     32  tadmc@augustmail.com
0.781  (  9.2 / 11.8)      8  AK <aknntp@yahoo.com>
0.776  (  5.4 /  7.0)      6  Marek Stepanek <mstep@t-online.de>
0.741  (  2.0 /  2.7)      6  "Eric J. Roode" <REMOVEsdnCAPS@comcast.net>
0.698  (  4.4 /  6.3)      7  Xavier Noria <fxn@hashref.com>
0.644  (  3.7 /  5.7)      9  stinkbomb <user@someserver123abc.com>
0.624  (  5.9 /  9.5)      6  bwalton@rochester.rr.com
0.579  ( 11.4 / 19.7)     16  tassilo.parseval@post.rwth-aachen.de
0.572  (  7.9 / 13.8)      9  david <dwlepage@yahoo.com>

Bottom 10 Posters by OCR (minimum of five posts)
================================================

         (kb)    (kb)
OCR      orig /  body  Posts  Address
-----  --------------  -----  -------

0.347  (  2.0 /  5.8)      6  Barry Kimelman <barryk2@SPAM-KILLER.mts.net>
0.344  ( 14.1 / 41.1)     38  Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>
0.342  (  2.0 /  5.9)      5  Jim Cochrane <jtc@flatland.dimensional.com>
0.333  (  1.5 /  4.5)      5  Jasper <jasper@mccrea.demon.co.uk>
0.312  ( 10.6 / 33.9)     18  Michael Budash <mbudash@sonic.net>
0.306  (  1.4 /  4.4)      6  "Bernard El-Hagin" <bernard.el-hagin@DODGE_THISlido-tech.net>
0.298  (  1.5 /  4.9)      5  "John W. Krahn" <krahnj@acm.org>
0.289  (  2.0 /  6.8)      8  Uri Guttman <uri@stemsystems.com>
0.260  (  5.0 / 19.4)     17  Chris Lowth <please@no.spam>
0.229  (  1.1 /  4.7)      5  "Tintin" <me@privacy.net>

43 posters (19%) had at least five posts.

Top 10 Threads by Number of Posts
=================================

Posts  Subject
-----  -------

   24  doubts on \n
   21  Determining String Membership
   19  text filter
   16  regexp question
   15  Array reference argument to subroutine problem
   15  why can't I last?
   15  Anyone For Golf? (Resistor Colour Codes)
   14  print to file safley
   13  new Perl feature request: call into shared libs
   11  Memory used by hashes

These threads accounted for 22.3% of all articles.

Top 10 Threads by Volume
========================

  (kb)   (kb)  (kb)  (kb)
Volume (  hdr/ body/ orig)  Posts  Subject
--------------------------  -----  -------

  49.2 (  2.6/ 46.3/ 45.7)      3  nms formmail with file upload
  48.6 ( 20.2/ 26.8/ 15.0)     24  doubts on \n
  42.8 ( 18.3/ 24.0/  9.4)     13  new Perl feature request: call into shared libs
  37.8 ( 20.4/ 14.7/  8.3)     19  text filter
  36.5 ( 19.2/ 16.0/  7.1)     21  Determining String Membership
  33.9 ( 12.8/ 19.7/  7.8)     15  Array reference argument to subroutine problem
  33.8 (  1.9/ 32.0/ 32.0)      2  Posting Guidelines for comp.lang.perl.misc ($Revision: 1.4 $)
  29.2 ( 13.1/ 13.7/  6.2)     14  print to file safley
  28.5 ( 15.1/ 13.1/  6.7)     16  regexp question
  27.3 ( 13.5/ 13.5/  6.1)     15  Anyone For Golf? (Resistor Colour Codes)

These threads accounted for 23.7% of the total volume.

Top 10 Threads by OCR (minimum of five posts)
=============================================

         (kb)    (kb)
OCR      orig /  body  Posts  Subject
-----  --------------  -----  -------

0.820  (  2.5/   3.0)      5  help
0.755  (  3.6/   4.8)      5  Can't access array element in Class::Struct structure
0.743  (  2.4/   3.3)      7  Can I use session Variables in Perl
0.738  (  5.8/   7.9)     10  Reverse assignment operator
0.714  (  5.3/   7.5)      8  Mangled Regular Expressions with '|' Operator
0.698  (  3.4/   4.8)      6  running a script on multiple files in a directory
0.638  (  2.1/   3.3)      5  remote control with perl
0.629  (  4.2/   6.7)      9  Editor with Perl as macro language?
0.613  (  5.2/   8.5)     10  Win32 Perl newsgroup?
0.613  (  2.4/   4.0)      6  How to execute find -exec in perl?

Bottom 10 Threads by OCR (minimum of five posts)
================================================

         (kb)    (kb)
OCR      orig /  body  Posts  Subject
-----  --------------  -----  -------

0.395  (  1.5 /  3.9)      5  Need help with regular expression
0.393  (  9.4 / 24.0)     13  new Perl feature request: call into shared libs
0.387  (  1.5 /  3.8)      6  disable pattern metacharacters?
0.375  (  5.8 / 15.5)     11  Memory used by hashes
0.340  (  3.4 / 10.1)     10  splitting an array into two arrays
0.336  (  2.9 /  8.7)      7  e-mail attachment.
0.333  (  2.6 /  7.9)      5  Looped variable interpolation
0.313  (  2.4 /  7.6)      5  Using an Environment variable in a regexp match
0.298  (  2.7 /  9.0)      8  Problem using CGI.pm and SSL.
0.258  (  3.0 / 11.5)     10  Really weird?!?

59 threads (38%) had at least five posts.

Top 10 Targets for Crossposts
=============================

Articles  Newsgroup
--------  ---------

       9  comp.lang.asm.x86
       4  comp.lang.c
       3  comp.lang.perl
       3  comp.lang.perl.modules
       2  comp.text.xml
       1  comp.protocols.snmp
       1  comp.databases
       1  news.answers
       1  comp.groupware.lotus-notes.programmer
       1  news.groups

Top 10 Crossposters
===================

Articles  Address
--------  -------

       5  Ilya Zakharevich <nospam-abuse@ilyaz.org>
       4  Philip Greer <philip@tildesoftware.com>
       2  dillon@SpamMinuSaccessdenied.darktech.org
       2  <jari.aalto@poboxes.com> (Jari Aalto+mail.perl)
       2  "Poul Kornmod" <pkornmod@hotmail.com>
       2  ivo welch <ivo.welch@anderson.ucla.edu>
       2  Walter Roberson <roberson@ibd.nrc-cnrc.gc.ca>
       2  "Matt Taylor" <para@tampabay.rr.com>
       1  "nobody" <nobody@nowhere.non>
       1  Kevin Easton <kevin@-nospam-pcug.org.au>


------------------------------

Date: Mon, 24 Mar 2003 12:04:18 GMT
From: "Blnukem" <blnukem@hotmail.com>
Subject: update value in flat file
Message-Id: <6vCfa.193226$b8.42346172@news4.srv.hcvlny.cv.net>

Hi all

What would be the best way to update a value in a pipe delimited flat file
say I wanted to update description3 quantity to 5. Should I read it all into
an array update that value and then just reprint it?

flat file format: Item| count

description1|3
description2|4
description3|6
description4|2
description5|0
description6|1

Thanx In Advance
Blnukem




------------------------------

Date: 24 Mar 2003 12:09:55 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: update value in flat file
Message-Id: <b5msij$4m4$2@mamenchi.zrz.TU-Berlin.DE>

Blnukem <blnukem@hotmail.com> wrote in comp.lang.perl.misc:
> Hi all
> 
> What would be the best way to update a value in a pipe delimited flat file
> say I wanted to update description3 quantity to 5. Should I read it all into
> an array update that value and then just reprint it?
> 
> flat file format: Item| count
> 
> description1|3
> description2|4
> description3|6
> description4|2
> description5|0
> description6|1

perldoc -q 'line in a file'

After so many years you should know better than to ask a FAQ.

Anno


------------------------------

Date: Mon, 24 Mar 2003 14:53:04 +0100
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: update value in flat file
Message-Id: <b5n2ka$2br8u5$1@ID-184292.news.dfncis.de>

Anno Siegel wrote:
> Blnukem <blnukem@hotmail.com> wrote in comp.lang.perl.misc:
>>What would be the best way to update a value in a pipe delimited flat file
>>say I wanted to update description3 quantity to 5. Should I read it all into
>>an array update that value and then just reprint it?
> 
> perldoc -q 'line in a file'
> 
> After so many years you should know better than to ask a FAQ.

But the answer may differ nowadays, right?

Unless you don't have Perl v5.8, I suggest that you ignore the FAQ 
answer, and use the Tie::File module instead.

/ Gunnar

-- 
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl



------------------------------

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.  

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 4753
***************************************


home help back first fref pref prev next nref lref last post