[17236] in Perl-Users-Digest
Perl-Users Digest, Issue: 4658 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Oct 18 21:10:48 2000
Date: Wed, 18 Oct 2000 18:10:21 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <971917821-v9-i4658@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Wed, 18 Oct 2000 Volume: 9 Number: 4658
Today's topics:
Re: Question: DBI or DF_file? <nospam@david-steuber.com>
Re: Regex for matching e-mail addresses <ianb@ot.com.au>
Re: Regex in a variable <fox@wanadoo.fr>
Re: regex substitute nodo70@my-deja.com
removing directories <Michael.Karner@gmx.at>
Re: removing directories <anders@wall.alweb.dk>
Re: removing directories <anders@wall.alweb.dk>
Re: Search, pad, replace (Martien Verbruggen)
Re: Sort Help Needed (Gwyn Judd)
Re: split on comma except when embedded inside quotes (Gwyn Judd)
Re: Statistics for comp.lang.perl.misc (Gwyn Judd)
Re: Statistics for comp.lang.perl.misc (brian d foy)
Tele Commute ONLY - PERL - Java - JS - CSS - HTML - Dre InternationalPERLjavaPRG@IJavaPerlPrg.com
Re: Tele Commute ONLY - PERL - Java - JS - CSS - HTML - <mauldin@netstorm.net>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 19 Oct 2000 01:01:08 GMT
From: David Steuber <nospam@david-steuber.com>
Subject: Re: Question: DBI or DF_file?
Message-Id: <m3u2a9bq5o.fsf@solo.david-steuber.com>
maiwang@home.com (R.) writes:
' -Can I use a DB created by Access 7 and access from perl? I gather this
' would solve the concurrent session problem.
There is a DBD::ODBC module for DBI. I don't know how it works under
the alleged operating system known as Windows. I'm using DBI with
DBD::Pg.pm myself.
Quite honestly, in this tyro's opinion, you should use DBI if it works
with your system. It is certain to be the Perl standard when talking
to databases.
As for cached connections, Apache handles that for me under linux
using Apache::DBI. Clever voodoo there. Each server instance has its
own database handle. The database deals with concurrency issues.
BTW, Access may not be what you want for a web site. You should use
SQL Server instead.
--
David Steuber | Perl apprentice. The axe did not stop the
NRA Member | mops and buckets from flooding my home.
ICQ# 91465842
*** http://www.david-steuber.com/ ***
------------------------------
Date: Thu, 19 Oct 2000 11:08:04 +1100
From: Ian Boreham <ianb@ot.com.au>
Subject: Re: Regex for matching e-mail addresses
Message-Id: <39EE3B64.5E000EAD@ot.com.au>
James Taylor wrote:
> (I wonder if
> there's a self-help group: Paranoid Control Freaks Anonymous?)
Who told you about PCFA? Was it Them? I thought I had arranged things
meticulously so no-one would find out!
Ian
------------------------------
Date: Thu, 19 Oct 2000 00:53:12 +0200
From: ElephantChild <fox@wanadoo.fr>
Subject: Re: Regex in a variable
Message-Id: <Pine.BSF.3.96.1001019004931.14751B-100000@nsmsr105.francetelecom.net>
On 18 Oct 2000, Peter J. Acklam wrote:
> Tristan Marly wrote:
>
> > However, I would like to put "/exe$/i" in a variable, but it
> > does not work:
> > $regex = '/exe$/i';
> > if ($filename =~ $regex) {
> > ...
> > }
>
> ElephantChild <fox@wanadoo.fr> writes:
>
> > Basically, you need to use eval.
>
> Are you sure?
Well, I was when I replied. :-/
> How about
>
> $regex = qr '(?i)exe$';
Nice. As I said (I think) the last time I saw it. And the previous one.
And the one before that. Now if I only would remember it once and for
all... :-)
--
Bungee jumping and skydiving are for wimps. If you want to experience
true gut-wrenching terror, have children. --Dusty Rhoades.
------------------------------
Date: Wed, 18 Oct 2000 23:32:02 GMT
From: nodo70@my-deja.com
Subject: Re: regex substitute
Message-Id: <8slbti$onb$1@nnrp1.deja.com>
Thanks.
In article <8sl254$kn9mq$3@ID-24002.news.cis.dfn.de>,
news@tinita.de wrote:
> hi,
> In comp.lang.perl.misc nodo70@my-deja.com wrote:
> > Can anyone help me with this perl script? I appreciate your help.
>
> oh and I forgot:
> read
> perldoc perlre
>
> tina
>
> --
> http://tinita.de \ enter__| |__the___ _ _ ___
> tina's moviedatabase \ / _` / _ \/ _ \ '_(_-< of
> search & add comments \ \__,_\___/\___/_| /__/ perception
> please don't email unless offtopic or followup is set. thanx
>
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Thu, 19 Oct 2000 00:25:08 +0200
From: "Michael F. Karner" <Michael.Karner@gmx.at>
Subject: removing directories
Message-Id: <39ee2347$0$25296@SSP1NO25.highway.telekom.at>
Hi,
Does anybody where to find a perlscript which walks recursive over a
directory tree and removes all empty directories so that in the end all
existing directories consist of files + not empty subdirectories ?
Thanks,
Mike
------------------------------
Date: Thu, 19 Oct 2000 00:56:06 +0200
From: Anders Lund <anders@wall.alweb.dk>
Subject: Re: removing directories
Message-Id: <VUpH5.7461$Tq1.247068@news010.worldonline.dk>
Michael F. Karner wrote:
> Hi,
>
> Does anybody where to find a perlscript which walks recursive over a
> directory tree and removes all empty directories so that in the end all
> existing directories consist of files + not empty subdirectories ?
>
> Thanks,
>
> Mike
>
perldoc -f rmdir:
rmdir FILENAME
rmdir Deletes the directory specified by FILENAME if
that directory is empty. If it succeeds it
returns true, otherwise it returns false and sets
`$!' (errno). If FILENAME is omitted, uses `$_'.
use File::Find;
find sub { rmdir if -d or print "$File::Find::dir/$_ is not empty\n" }, ".";
or from command line:
$perl -MFile::Find -e 'find sub { rmdir if -d or print "$File::Find::dir/$_
is not empty\n" }, "."'
- anders
--
[ the word wall - and the trailing dot - in my email address
is my _fire_wall - protecting me from the criminals abusing usenet]
------------------------------
Date: Thu, 19 Oct 2000 01:10:13 +0200
From: Anders Lund <anders@wall.alweb.dk>
Subject: Re: removing directories
Message-Id: <86qH5.7481$Tq1.247547@news010.worldonline.dk>
Anders Lund wrote:
> Michael F. Karner wrote:
>
> > Hi,
> >
> > Does anybody where to find a perlscript which walks recursive over a
> > directory tree and removes all empty directories so that in the end all
> > existing directories consist of files + not empty subdirectories ?
> >
> > Thanks,
> >
> > Mike
> >
>
>
> perldoc -f rmdir:
>
> rmdir FILENAME
>
> rmdir Deletes the directory specified by FILENAME if
> that directory is empty. If it succeeds it
> returns true, otherwise it returns false and sets
> `$!' (errno). If FILENAME is omitted, uses `$_'.
>
>
> use File::Find;
>
> find sub { rmdir if -d or print "$File::Find::dir/$_ is not empty\n" },
> ".";
Ooops :-o
of cause
find sub { if (-d) {rmdir or print ....}}
embarassing, goes for the oneliner as well...
>
> or from command line:
>
> $perl -MFile::Find -e 'find sub { rmdir if -d or print
> "$File::Find::dir/$_ is not empty\n" }, "."'
>
> - anders
>
-anders
--
[ the word wall - and the trailing dot - in my email address
is my _fire_wall - protecting me from the criminals abusing usenet]
------------------------------
Date: Thu, 19 Oct 2000 10:47:18 +1100
From: mgjv@tradingpost.com.au (Martien Verbruggen)
Subject: Re: Search, pad, replace
Message-Id: <slrn8usdk6.fji.mgjv@martien.heliotrope.home>
On Wed, 18 Oct 2000 11:04:55 -0400,
DesQuite <desquite@hotmail.com> wrote:
> Thanks. You're an asshole.
Oh really?
Well.. I'll be sure to remember you the next time you come along. I
should have known better than to help someone who isn't even willing to
do their own work.
Martien
--
Martien Verbruggen |
Interactive Media Division | I'm just very selective about what I
Commercial Dynamics Pty. Ltd. | accept as reality - Calvin
NSW, Australia |
------------------------------
Date: Thu, 19 Oct 2000 00:06:39 GMT
From: tjla@guvfybir.qlaqaf.bet (Gwyn Judd)
Subject: Re: Sort Help Needed
Message-Id: <slrn8useoc.bj3.tjla@thislove.dyndns.org>
I was shocked! How could Larry Rosler <lr@hpl.hp.com>
say such a terrible thing:
>In article <39ED552B.4A01D107@stomp.stomp.tokyo> on Wed, 18 Oct 2000
>00:45:47 -0700, Godzilla! <godzilla@stomp.stomp.tokyo> says...
>> @New_Array = map { $_ -> [0] } sort { $a -> [1] <=> $b -> [1] }
>> map { [$_, (split /¦/) [1]] } @Array;
>
>That is not a proper date sort, as one would discover in a few months.
What happens in a few months and how will the sort fail?
--
Gwyn Judd (print `echo 'tjla@guvfybir.qlaqaf.bet' | rot13`)
Regnant populi.
------------------------------
Date: Wed, 18 Oct 2000 22:56:52 GMT
From: tjla@guvfybir.qlaqaf.bet (Gwyn Judd)
Subject: Re: split on comma except when embedded inside quotes
Message-Id: <slrn8usalf.bj3.tjla@thislove.dyndns.org>
I was shocked! How could JA <jalford12@yahoo.co.uk>
say such a terrible thing:
<I said>
>>This is in the faq:
>>
>>perldoc -q 'How can I split a [character] delimited string except when'
>>
>>Hope that helps
>
>No documentation for perl FAQ keyword 'How' found
Hmm wonder why that didn't work. Try this:
perldoc -q 'How can I split'
--
Gwyn Judd (print `echo 'tjla@guvfybir.qlaqaf.bet' | rot13`)
"Nuclear war would really set back cable."
- Ted Turner
------------------------------
Date: Thu, 19 Oct 2000 00:07:31 GMT
From: tjla@guvfybir.qlaqaf.bet (Gwyn Judd)
Subject: Re: Statistics for comp.lang.perl.misc
Message-Id: <slrn8useq1.bj3.tjla@thislove.dyndns.org>
I was shocked! How could Jonathan Stowe <gellyfish@gellyfish.com>
say such a terrible thing:
>On Mon, 16 Oct 2000 14:56:17 -0000 Greg Bacon wrote:
>>
>> 432.7 ( 0.8/431.8/238.6) 1 "Wayne Paterson" <waynep@staff.intekom.com>
>
>WTF ? I must have missed that.
You didn't miss much :)
--
Gwyn Judd (print `echo 'tjla@guvfybir.qlaqaf.bet' | rot13`)
Margaret Knight (1903-1983).
Famous Dead Non-Theists
------------------------------
Date: Wed, 18 Oct 2000 20:50:10 -0400
From: brian@smithrenaud.com (brian d foy)
Subject: Re: Statistics for comp.lang.perl.misc
Message-Id: <brian-ya02408000R1810002050100001@news.panix.com>
In article <slrn8useq1.bj3.tjla@thislove.dyndns.org>, tjla@guvfybir.qlaqaf.bet (Gwyn Judd) posted:
> I was shocked! How could Jonathan Stowe <gellyfish@gellyfish.com>
> say such a terrible thing:
> >On Mon, 16 Oct 2000 14:56:17 -0000 Greg Bacon wrote:
> >>
> >> 432.7 ( 0.8/431.8/238.6) 1 "Wayne Paterson" <waynep@staff.intekom.com>
> >
> >WTF ? I must have missed that.
>
> You didn't miss much :)
no, he missed a lot, which is the point, i think. ;)
--
brian d foy
CGI Meta FAQ <URL:http://www.smithrenaud.com/public/CGI_MetaFAQ.html>
Perl Mongers <URL:http://www.perl.org/>
------------------------------
Date: Wed, 18 Oct 2000 22:28:50 GMT
From: InternationalPERLjavaPRG@IJavaPerlPrg.com
Subject: Tele Commute ONLY - PERL - Java - JS - CSS - HTML - DreamWeaver
Message-Id: <CupH5.3005$_o5.15638@typhoon.san.rr.com>
*** TELE COMMUTE ONLY ****
WEB PAGE PROGRAMMER
MUST HAVE EXCELLENT EXPERIENCE WITH:
* DREAMWEAVER (Large Domain Mgt.) PREFERRED
* DHTML AND CSS CAPABILITIES OF DREAMWEAVER
* WINDOWS NT 4.0 IIS 5.0 (server)
* WEB PROGRAMMING: PERL / CGI / JavaScript / DHTML / CSS / JAVA
* PROGRAMMING: C / Java
15 TO 40 HOURS PER WEEK
$15.00 to $25.00 per hour commensurate with experience.
* Using a Remote Control software utility called TIMBUKTU
* 2 people can work on the same computer simultaneously
even though thousands of miles apart..
* Timbuktu has an audio channel and chat features.
* High-Bandwidth Not necessary, but PREFERRED.
* Specific "Log-On' Schedule required.
* Flexible
* Prefer Mornings: Pacific Standard Time (PST),
but afternoons, ok.
* 2 to 3 hours per remomte 'log-on' session using Timbuktu
* 2 to 3 times per week minimum.
* Some work done off-line, but this is PRIMARILY a
real-time, log-on position.
* Instead of having a specific schedule at an office,
a specific computer log-on schedule is required.
* Please respond directly to:
Telecommuter@Law.com
------------------------------
Date: Wed, 18 Oct 2000 22:49:57 GMT
From: Jim Mauldin <mauldin@netstorm.net>
Subject: Re: Tele Commute ONLY - PERL - Java - JS - CSS - HTML - DreamWeaver
Message-Id: <39EE28B1.12EFD4C@netstorm.net>
InternationalPERLjavaPRG@IJavaPerlPrg.com wrote:
>
> *** TELE COMMUTE ONLY ****
>
> WEB PAGE PROGRAMMER
>
> MUST HAVE EXCELLENT EXPERIENCE WITH:
> * DREAMWEAVER (Large Domain Mgt.) PREFERRED
> * DHTML AND CSS CAPABILITIES OF DREAMWEAVER
> * WINDOWS NT 4.0 IIS 5.0 (server)
> * WEB PROGRAMMING: PERL / CGI / JavaScript / DHTML / CSS / JAVA
> * PROGRAMMING: C / Java
>
> 15 TO 40 HOURS PER WEEK
>
> $15.00 to $25.00 per hour commensurate with experience.
>
> * Using a Remote Control software utility called TIMBUKTU
> * 2 people can work on the same computer simultaneously
> even though thousands of miles apart..
> * Timbuktu has an audio channel and chat features.
>
> * High-Bandwidth Not necessary, but PREFERRED.
>
> * Specific "Log-On' Schedule required.
> * Flexible
> * Prefer Mornings: Pacific Standard Time (PST),
> but afternoons, ok.
> * 2 to 3 hours per remomte 'log-on' session using Timbuktu
> * 2 to 3 times per week minimum.
>
> * Some work done off-line, but this is PRIMARILY a
> real-time, log-on position.
> * Instead of having a specific schedule at an office,
> a specific computer log-on schedule is required.
>
> * Please respond directly to:
>
> Telecommuter@Law.com
This is a technical newsgroup, imbecile, not a place to dump insulting,
ignorant tripe.
-- Jim Mauldin
------------------------------
Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 16 Sep 99)
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: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.
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 V9 Issue 4658
**************************************