From joel at cts.com Tue May 2 22:31:13 2000 From: joel at cts.com (Joel Fentin) Date: Thu Aug 5 00:20:02 2004 Subject: Language performance comparisons (fwd) Message-ID: <3.0.4.32.20000502203113.007a1100@crash.cts.com> ~sdpm~ >---------- Forwarded message ---------- >Date: Sun, 30 Apr 2000 12:10:05 -0700 >From: John W Pierce >To: sysadmin-l@ucsd.edu >Subject: Language performance comparisons > >Preliminary results, information about the tests, source code for all tests, >and the datasets needed, are now at > >http://chesvc02.ucsd.edu/~jwp/LangTest/ -- Joel Fentin tel: 760-749-8863 FAX: 760-749-8864 email: joel@cts.com web: http://efm.simplenet.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From todd.rockhold at ontogen.com Wed May 3 13:06:49 2000 From: todd.rockhold at ontogen.com (Todd Rockhold) Date: Thu Aug 5 00:20:02 2004 Subject: FW: VPM - PPm problems. Message-ID: <00May3.111406pdt.118081@gateway.ontogen.com> ~sdpm~ The PDK mentioned below is Active State's Perl Development Kit. I have it and have used ppm but have not seen the problem. In case some of you San Diego Perl Mongers out there do see this, the info might be helpful... > -----Original Message----- > From: David Blank-Edelman [SMTP:dnb@ccs.neu.edu] > Sent: Tuesday, May 02, 2000 11:54 PM > To: PDK Mailing List > Subject: Re: VPM - PPm problems. > > George A Valencia writes: > > > Since I bought PDK, I am not able to use ppm. "verify" and "search" > gives an > > error message: > > mismatched tag at line 9, column 2, byte 612 at > > C:/Perl/site/lib/XML/Parser.pm line 183 > > Howdy- > I just got done debugging this very same problem. Here's what I had > to do to fix this, your mileage may vary. I believe the installation > of a new version of XML-Parser (2.28) caused some error checking > behave differently in the PPM program. > > After some debugging, the conclusion I came to was that you will see > this message for every entity in your ppm config file > (usually c:\perl\site\lib\ppm.xml) whose entity cannot be > contacted. For instance, if you've ever loaded anything from Jenda's > archive (before the Jenda.Krynicky.cz name went temporarily on > hiatus), or anything from your hard disk and then wiped the > directory, you will receive this message. > > My fix was to edit the ppm.xml file by hand (caution! make a backup, > you can do more harm than good if you get this wrong) to fix those > LOCATION entries which were causing problems. > > Your next question may be "how do I know which entries are causing a > problem?". Here's how I found out: > > 1) run "ppm verify" and note the last package which was mentioned > > 2) run the ppm program in the debugger, preferably in a separate > command window (e.g. perl -d c:\perl\bin\ppm.pl) > > 3) Type "b 867" to set a breakpoint at the right line in the > verify_packages subroutine. > > 4) Type "c" to continue, enter "verify" at the prompt. > > 5) In a moment you will get a debugger prompt again. Type "x keys > %info". > > You should now get a list of all the packages installed in the order > PPM is going to process them. Look for the last package you saw in > step 1. If you find the package in the list generated by > "x keys %info", the very _next_ one on the list is your problem > child. > > 6) Edit it's entry in ppm.xml. Repeat as often as necessary. > > I suspect the above is a bit more roundabout than one needs to be, > but it did eventually solve my problem. Hope this helps other folks > as well. > > Respectfully, > David N. Blank-Edelman > Director of Technology > College of Computer Science > Northeastern University > > --- > You are currently subscribed to pdk as: [todd.rockhold@ontogen.com] > To unsubscribe, forward this message to > leave-pdk-102647B@lyris.ActiveState.com > For non-automated Mailing List support, send email to > ListHelp@ActiveState.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From webtemp at ucsd-pps.ucsd.edu Wed May 3 14:45:24 2000 From: webtemp at ucsd-pps.ucsd.edu (Michael DeVicariis) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module Message-ID: <000601bfb538$1fb031a0$edc3ef84@pps195-237.ucsd.edu> ~sdpm~ I'm trying to write a short script that automates the download of a file using Net::FTP. I can't seem to find a copy of that module anywhere. Is it now replaced by Net::TFTP? Does anyone have a copy it Net::FTP? TIA, Michael DeVicariis Web Administrator Programmer/Analyst UCSD Auxiliary & Plant Services (858) 534-0700 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From jeff at planetoid.net Wed May 3 15:00:33 2000 From: jeff at planetoid.net (jeff) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module References: <000601bfb538$1fb031a0$edc3ef84@pps195-237.ucsd.edu> Message-ID: <39108561.844A40F2@planetoid.net> ~sdpm~ its part of the libnet module. the mod dir http://www.perl.com/CPAN-local/modules/by-module/Net/ and the readme for libnet http://www.perl.com/CPAN-local/modules/by-module/Net/libnet-1.0703.readme jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From webtemp at ucsd-pps.ucsd.edu Wed May 3 16:53:50 2000 From: webtemp at ucsd-pps.ucsd.edu (Michael DeVicariis) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module In-Reply-To: <39108561.844A40F2@planetoid.net> Message-ID: <000801bfb54a$10c02b20$edc3ef84@pps195-237.ucsd.edu> ~sdpm~ I'm trying to download(ftp) a file based on the current date. When I grab the year from localtime(), I get 100. When I print the complete time, I get 2000. Is this supposed to be the correct response? ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(); print "\nmonth: $mon"; print "\nyear: $year"; $myDate = localtime(); print "\n\n$myDate"; month: 4 year: 100 Wed May 3 14:44:03 2000 Michael DeVicariis Web Administrator Programmer/Analyst UCSD Auxiliary & Plant Services (858) 534-0700 -----Original Message----- From: owner-san-diego-pm-list@pm.org [mailto:owner-san-diego-pm-list@pm.org]On Behalf Of jeff Sent: Wednesday, May 03, 2000 1:01 PM To: Michael DeVicariis Cc: sdpm Subject: Re: Net::FTP module ~sdpm~ its part of the libnet module. the mod dir http://www.perl.com/CPAN-local/modules/by-module/Net/ and the readme for libnet http://www.perl.com/CPAN-local/modules/by-module/Net/libnet-1.0703.readme jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From webtemp at ucsd-pps.ucsd.edu Wed May 3 17:22:58 2000 From: webtemp at ucsd-pps.ucsd.edu (Michael DeVicariis) Date: Thu Aug 5 00:20:02 2004 Subject: FW: Net::FTP module Message-ID: <000901bfb54e$2300e140$edc3ef84@pps195-237.ucsd.edu> ~sdpm~ In addition, the month returns April(4) instead of May(5). Any ideas why? Michael DeVicariis Web Administrator Programmer/Analyst UCSD Auxiliary & Plant Services (858) 534-0700 -----Original Message----- From: Michael DeVicariis [mailto:webtemp@ucsd-pps.ucsd.edu] Sent: Wednesday, May 03, 2000 2:54 PM To: sdpm Subject: RE: Net::FTP module I'm trying to download(ftp) a file based on the current date. When I grab the year from localtime(), I get 100. When I print the complete time, I get 2000. Is this supposed to be the correct response? ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(); print "\nmonth: $mon"; print "\nyear: $year"; $myDate = localtime(); print "\n\n$myDate"; month: 4 year: 100 Wed May 3 14:44:03 2000 Michael DeVicariis Web Administrator Programmer/Analyst UCSD Auxiliary & Plant Services (858) 534-0700 -----Original Message----- From: owner-san-diego-pm-list@pm.org [mailto:owner-san-diego-pm-list@pm.org]On Behalf Of jeff Sent: Wednesday, May 03, 2000 1:01 PM To: Michael DeVicariis Cc: sdpm Subject: Re: Net::FTP module ~sdpm~ its part of the libnet module. the mod dir http://www.perl.com/CPAN-local/modules/by-module/Net/ and the readme for libnet http://www.perl.com/CPAN-local/modules/by-module/Net/libnet-1.0703.readme jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Wed May 3 17:21:33 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:02 2004 Subject: parsing Message-ID: <3910A66D.8851B919@sdsc.edu> How's it going, can anyone help me with regular expressions!! Here is the string: 4129280 bytes sent in 3.62 seconds (1142.26 Kbytes/sec) I need: 1142.26 out of it. Ya, I'm new to perl so any advice would be great. Thanks, Steve -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000503/0007a4ac/smeier.vcf From eugenet at mailcity.com Wed May 3 17:27:30 2000 From: eugenet at mailcity.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module Message-ID: ~sdpm~ http://www.perl.com/CPAN-local/doc/manual/html/pod/perlfunc/localtime.html -- On Wed, 3 May 2000 15:22:58 Michael DeVicariis wrote: >~sdpm~ >In addition, the month returns April(4) instead of May(5). Any ideas why? > > > >Michael DeVicariis >Web Administrator >Programmer/Analyst >UCSD Auxiliary & Plant Services >(858) 534-0700 > > > >-----Original Message----- >From: Michael DeVicariis [mailto:webtemp@ucsd-pps.ucsd.edu] >Sent: Wednesday, May 03, 2000 2:54 PM >To: sdpm >Subject: RE: Net::FTP module > > >I'm trying to download(ftp) a file based on the current date. When I grab >the year from localtime(), I get 100. When I print the complete time, I get >2000. Is this supposed to >be the correct response? > > >($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(); >print "\nmonth: $mon"; >print "\nyear: $year"; > >$myDate = localtime(); >print "\n\n$myDate"; > > > >month: 4 >year: 100 > >Wed May 3 14:44:03 2000 > Get your FREE Email at http://mailcity.lycos.com Get your PERSONALIZED START PAGE at http://my.lycos.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Wed May 3 17:32:16 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module References: <000801bfb54a$10c02b20$edc3ef84@pps195-237.ucsd.edu> Message-ID: <3910A8F0.64E806C4@velocigen.com> ~sdpm~ Michael DeVicariis wrote: > I'm trying to download(ftp) a file based on the current date. When I grab > the year from localtime(), I get 100. When I print the complete time, I get > 2000. Is this supposed to be the correct response? > That's absolutely correct. In list context, locatime() reports the year as the number of years since 1900. In scalar context, localtime will return a more human-readable timestamp. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smith at newmediamerchants.com Wed May 3 17:01:41 2000 From: smith at newmediamerchants.com (Jarom Smith) Date: Thu Aug 5 00:20:02 2004 Subject: Net::FTP module Message-ID: ~sdpm~ webtemp@ucsd-pps.ucsd.edu writes: >I'm trying to download(ftp) a file based on the current date. When I grab >the year from localtime(), I get 100. When I print the complete time, I >get >2000. Is this supposed to >be the correct response? the time you get back from localtime is an offset from the year 1900, probably more for compatibility with C's localtime() than for any other reason. See the documentation on localtime in your favorite book or online: perldoc perlfunc (skip down to the localtime part) localtime EXPR Converts a time as returned by the time function to a 9-element array with the time analyzed for the local time zone. Typically used as follows: # 0 1 2 3 4 5 6 7 8 ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time); All array elements are numeric, and come straight out of a struct tm. In particular this means that $mon has the range 0..11 and $wday has the range 0..6 with sunday as day 0. Also, $year is the number of years since 1900, that is, $year is 123 in year 2023. If EXPR is omitted, uses the current time (localtime(time)). In a scalar context, returns the ctime(3) value: $now_string = localtime; # e.g., "Thu Oct 13 04:54:34 1994" Also see the Time::Local module, and the strftime(3) and mktime(3) function available via the POSIX module. jarom smith vp technology new media merchants, inc. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugenet at mailcity.com Wed May 3 17:33:20 2000 From: eugenet at mailcity.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:02 2004 Subject: parsing Message-ID: ~sdpm~ print $1 if "4129280 bytes sent in 3.62 seconds (1142.26 Kbytes/sec)" =~ /seconds \(([\d.]+) / see http://www.perl.com/CPAN-local/doc/manual/html/pod/perlre.html and http://www.bookpool.com/.x/rixy56sr96/ss/1?qs=regular+ex -- On Wed, 03 May 2000 15:21:33 Steve Meier wrote: > >How's it going, > >can anyone help me with regular expressions!! > >Here is the string: 4129280 bytes sent in 3.62 seconds (1142.26 >Kbytes/sec) > >I need: 1142.26 out of it. > >Ya, I'm new to perl so any advice would be great. > >Thanks, > >Steve Get your FREE Email at http://mailcity.lycos.com Get your PERSONALIZED START PAGE at http://my.lycos.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Wed May 3 17:51:27 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:02 2004 Subject: parsing References: <3910A66D.8851B919@sdsc.edu> Message-ID: <3910AD6F.A3633981@velocigen.com> ~sdpm~ Steve Meier wrote: > can anyone help me with regular expressions!! > > Here is the string: 4129280 bytes sent in 3.62 seconds (1142.26 > Kbytes/sec) > > I need: 1142.26 out of it. > my $string = '4129280 bytes sent in 3.62 seconds (1142.26 Kbytes/sec)'; my $result; if ($string =~ /\((.+?)\s/) { $result = $1; } print qq{The result is $result.\n}; Basically, you're looking for stuff between the first ( and the next space after that. By enclosing it in parentheses, Perl stores it in $1; if you had another set of parentheses the result would be stored in $2, etc. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Wed May 3 17:58:34 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:02 2004 Subject: FW: Net::FTP module References: <000901bfb54e$2300e140$edc3ef84@pps195-237.ucsd.edu> Message-ID: <3910AF1A.D28E8A85@velocigen.com> ~sdpm~ Michael DeVicariis wrote: > In addition, the month returns April(4) instead of May(5). Any ideas why? > localtime() assumes that you'll be applying the number returned to an array, like so: my @month = qw(Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov); my $this_month = $month[localtime()[4]]; Note that in the array, Jan is entry 0, May is entry 4 and June is entry 5. To get the numbered month as we normally think of it, add one. See Eugene's reference or http://www.perl.com/pub/doc/manual/html/pod/perlfunc/localtime.html for more detail. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From astewart at spawar.navy.mil Wed May 3 19:00:59 2000 From: astewart at spawar.navy.mil (Alan Stewart) Date: Thu Aug 5 00:20:02 2004 Subject: parsing In-Reply-To: Message-ID: <200005032256.PAA14339@droid.nosc.mil> ~sdpm~ On 3 May 00, at 15:33, Eugene Tsyrklevich wrote: >~sdpm~ >print $1 if "4129280 bytes sent in 3.62 seconds (1142.26 Kbytes/sec)" =~ >/seconds \(([\d.]+) / > or just: print $1 if "4129280 bytes sent in 3.62 seconds (1142.26 Kbytes/sec)" =~ /\((.+?) /; BTW, there is a space between the ending ) and /. --------------------------------------------------------------- Alan Stewart )-[]-( Electronics Engineer Code D621 ~ ~ Network Operations SPAWARSYSCEN ~ ~ \ Satellite Communications 53560 Hull St ( ~ ~ ) tel (619)524-3625 San Diego,CA __|___ /| fax (619)524-2607 92152-5001 ^\____/^^^^^^\ __| |_ astewart@spawar.navy.mil ------------^^^^^^^^^^^^^^^\__|______|_------------------------ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From comeaujr at sd.conexant.com Thu May 4 12:29:41 2000 From: comeaujr at sd.conexant.com (John R. Comeau) Date: Thu Aug 5 00:20:02 2004 Subject: calling an object's ancestor method References: <200005032256.PAA14339@droid.nosc.mil> Message-ID: <200005041729.KAA22653@pirr.sd.conexant.com> ~sdpm~ Does anyone know how to force Perl to start it's search for an object's method in its immediate ancestors' classes? The $self->SUPER::method (); syntax start's the search in the ancestrial classes of the class in which the $self->SUPER::method () call is made, not in the ancestrial classes of the object itself. That's useful in some situations, but I have a situation where I need a SUPER-like syntax to start the search in the object's ancestors. On page 178 of _Object Oriented Perl_, Conway gives an example of searching through the ISA array of the object's class. I could adapt this technique to my situation to manually perform the search for the method, but I wondered if there isn't a built-in way of doing it. Thanks. -John ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Thu May 4 16:07:19 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:02 2004 Subject: parsing References: <3910A66D.8851B919@sdsc.edu> <3910AD6F.A3633981@velocigen.com> Message-ID: <3911E687.9B93F56C@sdsc.edu> > Sorry to bother you again but I have another one for you if you have the time. I have my ping parsed down to this line: Minimum = 0ms, Maximum = 0ms, Average = 0ms I need to parse out 0ms after "Average =" These regular expressions are a killer! I appreciate your help. Look forward to hearing from you, Steve -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000504/3f0ee0d3/smeier.vcf From comeaujr at sd.conexant.com Thu May 4 16:18:02 2000 From: comeaujr at sd.conexant.com (John R. Comeau) Date: Thu Aug 5 00:20:02 2004 Subject: parsing In-Reply-To: <3911E687.9B93F56C@sdsc.edu> (message from Steve Meier on Thu, 04 May 2000 14:07:19 -0700) References: <3910A66D.8851B919@sdsc.edu> <3910AD6F.A3633981@velocigen.com> <3911E687.9B93F56C@sdsc.edu> Message-ID: <200005042118.OAA23884@pirr.sd.conexant.com> ~sdpm~ >>>>> "Steve" == Steve Meier writes: Steve> I have my ping parsed down to this line: Steve> Minimum = 0ms, Maximum = 0ms, Average = 0ms Steve> I need to parse out 0ms after "Average =" Try this: $string = 'Minimum = 0ms, Maximum = 0ms, Average = 0ms'; $string =~ /Average\s+=\s+(\d+ms)/; $average = $1; -John ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Thu May 4 16:26:55 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:02 2004 Subject: parsing References: <3910A66D.8851B919@sdsc.edu> <3910AD6F.A3633981@velocigen.com> <3911E687.9B93F56C@sdsc.edu> Message-ID: <3911EB1F.EE4F0744@velocigen.com> ~sdpm~ Steve Meier wrote: > Sorry to bother you again but I have another one for you if you have the time. > I always have the time for Perl problems. They're fun! :) > I have my ping parsed down to this line: > > Minimum = 0ms, Maximum = 0ms, Average = 0ms > > I need to parse out 0ms after "Average =" > my $string = 'Minimum = 0ms, Maximum = 0ms, Average = 0ms'; my $result; if ($string =~ /Average.+?\s(.+?)$/) { $result = $1; } print qq{The result is $result.\n}; Basically, you're looking for 'Average', then some characters until you get to whitespace, then the thing you want, then the end of the line. > These regular expressions are a killer! I appreciate your help. > You might want to check out the _Perl_Pocket_Reference_ by Johan Vromans. It has a really handly reference on regular expressions that's saved my butt many a time. Cheers, ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smith at newmediamerchants.com Thu May 4 15:57:58 2000 From: smith at newmediamerchants.com (Jarom Smith) Date: Thu Aug 5 00:20:02 2004 Subject: Re(2): parsing Message-ID: ~sdpm~ smeier@sdsc.edu writes: >I have my ping parsed down to this line: > > Minimum = 0ms, Maximum = 0ms, Average = 0ms > > >I need to parse out 0ms after "Average =" come on, you have to put a LITTLE effort into it... You probably could have figured this one out by yourself. $string =~ m/Average\s+=\s+(\d+ms)/; $what_you_want = $1; There are many different ways to do this, all of them valid to one degree or another. It depends on how flexible/robust you want your match to be. jarom smith vp technology new media merchants, inc. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From canetguy at home.com Wed May 17 16:39:43 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:02 2004 Subject: Perl Mongers Update. Message-ID: <200005171439430095.5081EB07@mail> ~sdpm~ Howdy Monger! Here is a little information about up and coming meetings: Our next meeting is on May 17, 2000 at 7:00pm. Location and directions are on the web page. The Perl Monger's server is being setup this month. Hopefully by the 17th, we will be able to create shell accounts for all members. I will be posting bios of our members on the web site after our next meeting. This mean that I will need a paragraph or two about you, how and why you use Perl, where you work, your private URL, email address, what you do for fun, etc. On the 17th, there will be at least one digital camera for those who would like to have their picture included with the bio. If you don't want a bio posted on http://SanDiego.pm.org, don't worry, we won't force it out of you :) During the May meeting, along with our regular mingling and chatting, we will be talking about advanced data structures in Perl. These data structures (lists of lists, hashes of hashes, etc.) are constructed using references. So, try to bring in a small snippet of code where you used such a structure - we will talk about it!!! Also, bring in any code you want to brag about or have questions about! There has been no word yet from Randal Schwartz. I will be trying to contact him on a more frequent basis. -Garrett 858-720-1789 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From canetguy at home.com Fri May 5 10:45:07 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:02 2004 Subject: Perl Mongers Message-ID: <200005050845070568.5463A526@mail> ~sdpm~ If anyone has emailed me at adms1@cts.com, please send the message to canetguy@home.com. Somehow, about 400 email messages of mine were deleted off the cts.com servers..... arg!!! And no, none of them were the VIRUS!! -Garrett Casey 858-720-1789 canetguy@home.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Thu May 11 13:29:24 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:02 2004 Subject: ping script Message-ID: <391AFC04.5F60FC3@sdsc.edu> How's it going, Anyone have a NT ping script that displays the ping stats for a given host? Thanks, Steve -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000511/32ec8d24/smeier.vcf From artlung at artlung.com Thu May 11 16:07:37 2000 From: artlung at artlung.com (Joe Crawford) Date: Thu Aug 5 00:20:02 2004 Subject: ping script In-Reply-To: <391AFC04.5F60FC3@sdsc.edu> Message-ID: ~sdpm~ On Thu, 11 May 2000, Steve Meier wrote: > Anyone have a NT ping script that displays the ping stats for a given > host? I believe ping is built into all versions of NT (maybe even all versions of Windows since 95). I'm at a loss as to how this is a perl question - but I may be missing something. - Joe -- Joe Crawford...........electronic mail -> mailto:joe@artlung.com member......international mailing list -> http://evolt.org/ founder..San Diego/CA/USA mailing list -> http://www.websandiego.org/ Web Designer/etc.............about(me) -> http://www.artlung.com/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From kynn-edapta at idyllmtn.com Thu May 11 16:21:33 2000 From: kynn-edapta at idyllmtn.com (Kynn Bartlett) Date: Thu Aug 5 00:20:02 2004 Subject: ping script and The Next Meeting In-Reply-To: References: <391AFC04.5F60FC3@sdsc.edu> Message-ID: <4.2.0.58.20000511141955.00b74980@mail.idyllmtn.com> ~sdpm~ At 02:07 PM 5/11/2000 , Joe Crawford wrote: >I'm at a loss as to how this is a perl question - but I may be missing >something. Well, someone could always rewrite ping in Perl, I suppose. But most likely he is writing a Perl script and wants to incorporate a system call to ping into it? On another topic: When and where is the next meeting of San Diego Perl Mongers? I actually wrote some Perl this month, so I suppose I could bring a sample of my code for everyone to laugh at. :) --K -- Kynn Bartlett http://www.kynn.com/ Director of Accessibility, edapta http://www.edapta.com/ Chief Technologist, Idyll Mountain Internet http://www.idyllmtn.com/ AWARE Center Director http://www.awarecenter.org/ Next of Kynn: a quasi-regular web log http://www.kynn.com/next/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugenet at mailcity.com Thu May 11 20:17:49 2000 From: eugenet at mailcity.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:02 2004 Subject: ping script Message-ID: ~sdpm~ http://www.perl.com/pub/doc/manual/html/lib/Net/Ping.html -- On Thu, 11 May 2000 11:29:24 Steve Meier wrote: > >How's it going, > >Anyone have a NT ping script that displays the ping stats for a given >host? > >Thanks, > >Steve > Get your FREE Email at http://mailcity.lycos.com Get your PERSONALIZED START PAGE at http://my.lycos.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From canetguy at home.com Thu May 11 20:26:38 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:02 2004 Subject: ping script and The Next Meeting In-Reply-To: <4.2.0.58.20000511141955.00b74980@mail.idyllmtn.com> References: <391AFC04.5F60FC3@sdsc.edu> <4.2.0.58.20000511141955.00b74980@mail.idyllmtn.com> Message-ID: <200005111826380662.755EA9FA@mail> ~sdpm~ Kynn, The next meeting is Wed May 17th at 7:00pm. The location with directions is on http://SanDiego.pm.org Along with normal networking and chatting, we will be talking about advanced data structures (hashes of hashes, lists of lists, etc.) If you have code, please bring it to the meeting! -Garrett Casey adms1@cts.com canetguy@home.com *********** REPLY SEPARATOR *********** On 5/11/00 at 2:21 PM Kynn Bartlett wrote: >~sdpm~ >At 02:07 PM 5/11/2000 , Joe Crawford wrote: >>I'm at a loss as to how this is a perl question - but I may be missing >>something. > >Well, someone could always rewrite ping in Perl, I suppose. But >most likely he is writing a Perl script and wants to incorporate >a system call to ping into it? > >On another topic: > >When and where is the next meeting of San Diego Perl Mongers? I >actually wrote some Perl this month, so I suppose I could bring >a sample of my code for everyone to laugh at. :) > >--K > >-- >Kynn Bartlett http://www.kynn.com/ >Director of Accessibility, edapta http://www.edapta.com/ >Chief Technologist, Idyll Mountain Internet http://www.idyllmtn.com/ >AWARE Center Director http://www.awarecenter.org/ >Next of Kynn: a quasi-regular web log http://www.kynn.com/next/ > >~sdpm~ > >The posting address is: san-diego-pm-list@hfb.pm.org > >List requests should be sent to: majordomo@hfb.pm.org > >If you ever want to remove yourself from this mailing list, >you can send mail to with the following >command in the body of your email message: > > unsubscribe san-diego-pm-list > >If you ever need to get in contact with the owner of the list, >(if you have trouble unsubscribing, or have questions about the >list itself) send email to . >This is the general rule for most mailing lists when you need >to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Tue May 16 09:26:28 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:02 2004 Subject: ping Message-ID: <39215A94.51120AB6@sdsc.edu> Could someone tell me what I am doing wrong? What I want to do is look at each line that comes in on a ping. Eventually I will add regexp that will extract what I want out, but I am not going to worry that until I get the basics working. I know this is how you would go about it if it was a file that you wanted to look at line by line. Any help is greatly appreciated. $ping = "/usr/sbin/ping"; open (PING, "$ping $desthost "); while () { printf $_; } close(PING); -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000516/ddefbc6a/smeier.vcf From ashah at binevolve.com Tue May 16 10:40:38 2000 From: ashah at binevolve.com (Alex Shah) Date: Thu Aug 5 00:20:02 2004 Subject: ping In-Reply-To: <39215A94.51120AB6@sdsc.edu> Message-ID: ~sdpm~ I believe you are missing a '|' in your open statment: open(PING, "| ping blah.com"); will allow interprocess communication to occur, otherwise you will be opening the file itself. On Tue, 16 May 2000, Steve Meier wrote: > > > Could someone tell me what I am doing wrong? What I want to do is look > at each line that comes in on a ping. Eventually I will add regexp that > will extract what I want out, but I am not going to worry that until I > get the basics working. I know this is how you would go about it if it > was a file that you wanted to look at line by line. > > Any help is greatly appreciated. > > > $ping = "/usr/sbin/ping"; > > open (PING, "$ping $desthost "); > > while () > { > printf $_; > } > close(PING); > ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From kynn-edapta at idyllmtn.com Tue May 16 10:28:02 2000 From: kynn-edapta at idyllmtn.com (Kynn Bartlett) Date: Thu Aug 5 00:20:02 2004 Subject: ping In-Reply-To: <39215A94.51120AB6@sdsc.edu> References: <39215A94.51120AB6@sdsc.edu> Message-ID: ~sdpm~ At 7:26 AM -0700 5/16/00, Steve Meier wrote: >Could someone tell me what I am doing wrong? What I want to do is look >at each line that comes in on a ping. Okay. >$ping = "/usr/sbin/ping"; > >open (PING, "$ping $desthost "); This is usually used to open a file, not to run a command. You could always use the somewhat icky backtick operator to slurp the output of ping into a variable. >while () > { > printf $_; > } >close(PING); @ping = split(/\n/, `$ping $desthost`); Perl purists, how awful is this? -- -- Kynn Bartlett http://www.kynn.com/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From astewart at spawar.navy.mil Tue May 16 12:09:01 2000 From: astewart at spawar.navy.mil (Alan Stewart) Date: Thu Aug 5 00:20:02 2004 Subject: ping In-Reply-To: References: <39215A94.51120AB6@sdsc.edu> Message-ID: <200005161603.JAA00533@droid.nosc.mil> ~sdpm~ On 16 May 00, at 8:40, Alex Shah wrote: >~sdpm~ >I believe you are missing a '|' in your open statment: > >open(PING, "| ping blah.com"); Put the pipe on the other end, ping feeds the pipe: open(PING, "ping blah.com |"); > >will allow interprocess communication to occur, otherwise you will be >opening the file itself. > ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Tue May 16 11:23:21 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:02 2004 Subject: ping References: <39215A94.51120AB6@sdsc.edu> <200005161603.JAA00533@droid.nosc.mil> Message-ID: <392175F9.2A1C7831@sdsc.edu> yep, that worked! Thanks everyone... Alan Stewart wrote: > ~sdpm~ > On 16 May 00, at 8:40, Alex Shah wrote: > > >~sdpm~ > >I believe you are missing a '|' in your open statment: > > > >open(PING, "| ping blah.com"); > > Put the pipe on the other end, ping feeds the pipe: > open(PING, "ping blah.com |"); > > > > >will allow interprocess communication to occur, otherwise you will be > >opening the file itself. > > > > ~sdpm~ > > The posting address is: san-diego-pm-list@hfb.pm.org > > List requests should be sent to: majordomo@hfb.pm.org > > If you ever want to remove yourself from this mailing list, > you can send mail to with the following > command in the body of your email message: > > unsubscribe san-diego-pm-list > > If you ever need to get in contact with the owner of the list, > (if you have trouble unsubscribing, or have questions about the > list itself) send email to . > This is the general rule for most mailing lists when you need > to contact a human. -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000516/69632bff/smeier.vcf From canetguy at home.com Tue May 16 16:12:44 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:02 2004 Subject: Perl meeting soon Message-ID: <200005161412440940.8E360481@mail> ~sdpm~ Just wanted to remind you that our next Perl Mongers meeting is tomorrow night at 7:00. The location of the meeting and directions can be found at http://SanDiego.pm.org. The primary group discussion will be about Advanced Data Structures using References (made easy:). Be sure to bring your code! Also, there will be a digital camera to take pictures for online member bios. When our server is ready, we will be posting the pictures and bios on the web site. If you would like to be profiled on SanDiego.pm.org, bring a brief bio to the meeting. Bios could include where you work, your hobbies, how you use Perl, etc. See you tomorrow!! -Garrett Casey 858 720 1789 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From jeff at planetoid.net Tue May 16 16:18:33 2000 From: jeff at planetoid.net (jeff) Date: Thu Aug 5 00:20:03 2004 Subject: best way to define package constants Message-ID: <3921BB28.C75BA311@planetoid.net> ~sdpm~ what is the best way to define a package constant? If I do package PKGNAME; $PKGNAME::var = "foo"; the variable can be modified outside the package. But I don;t want that. Or I can make it a my and create a get routine for it. Or what? -- Jeff Saenz jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From tdarugar at velocigen.com Tue May 16 16:33:28 2000 From: tdarugar at velocigen.com (Parand T. Darugar) Date: Thu Aug 5 00:20:03 2004 Subject: best way to define package constants References: <3921BB28.C75BA311@planetoid.net> Message-ID: <3921BEA8.D4A2FEA6@velocigen.com> ~sdpm~ Dear Jeff, > what is the best way to define a package constant? If I do I think something like: package PKGNAME; use constant var => "foo"; might work. > package PKGNAME; > $PKGNAME::var = "foo"; > > the variable can be modified outside the package. But I don;t want that. > Or I can make it a my and create a get routine for it. Or what? Bes, Parand Tony Darugar tdarugar@velocigen.com 858-622-1164 High Performance Perl Server Pages 858-622-0303 fax VelociGen XML Server http://www.velocigen.com/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From canetguy at home.com Tue May 16 16:36:09 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:03 2004 Subject: best way to define package constants In-Reply-To: <3921BB28.C75BA311@planetoid.net> References: <3921BB28.C75BA311@planetoid.net> Message-ID: <200005161436090290.8E4B723F@mail> ~sdpm~ Jeff, You would probably want to use the constant module. You can find information about it at http://www.perl.com/pub/doc/manual/html/lib/constant.html -Garrett *********** REPLY SEPARATOR *********** On 5/16/00 at 2:18 PM jeff wrote: >~sdpm~ >what is the best way to define a package constant? If I do > > package PKGNAME; > $PKGNAME::var = "foo"; > >the variable can be modified outside the package. But I don;t want that. >Or I can make it a my and create a get routine for it. Or what? > > >-- >Jeff Saenz >jeff@planetoid.net > > >~sdpm~ > >The posting address is: san-diego-pm-list@hfb.pm.org > >List requests should be sent to: majordomo@hfb.pm.org > >If you ever want to remove yourself from this mailing list, >you can send mail to with the following >command in the body of your email message: > > unsubscribe san-diego-pm-list > >If you ever need to get in contact with the owner of the list, >(if you have trouble unsubscribing, or have questions about the >list itself) send email to . >This is the general rule for most mailing lists when you need >to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From jeff at planetoid.net Tue May 16 17:26:38 2000 From: jeff at planetoid.net (jeff) Date: Thu Aug 5 00:20:03 2004 Subject: assignment to dynamic namespace variables Message-ID: <3921CB1E.8A303826@planetoid.net> ~sdpm~ Thanks for the help on the constants. (Although, I'm not sure the overhead is worth it.) And I have another one.... How can I assign to variables in a namespace dynamically? For example, how can I assign to the variable $C::varname if varname is determined at run-time? Say I was trying to assign all variables in the namespace C to values in a hash, where the hash key should the var name. $C:: = $hash{$varname}; thanks again.... -- Jeff Saenz jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rkleeman at neta.com Tue May 16 17:39:48 2000 From: rkleeman at neta.com (Bobby Kleemann) Date: Thu Aug 5 00:20:03 2004 Subject: assignment to dynamic namespace variables In-Reply-To: <3921CB1E.8A303826@planetoid.net> Message-ID: ~sdpm~ On Tue, 16 May 2000, jeff wrote: > ~sdpm~ > Thanks for the help on the constants. (Although, I'm not sure the > overhead is worth it.) And I have another one.... > > How can I assign to variables in a namespace dynamically? For example, > how > can I assign to the variable $C::varname if varname is determined at > run-time? > > Say I was trying to assign all variables in the namespace C to values in > a hash, where the hash key should the var name. > > $C:: = $hash{$varname}; > > thanks again.... You'll get the strict to yell at you if you do it this way, so you'll probably want to turn it off (you do have it on normally, right?): { no strict 'refs'; ${ 'C::' . $varname } = $hash{$varname}; } _ _ _ Bobby Kleemann http://www.neta.com/~rkleeman/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From astewart at spawar.navy.mil Tue May 16 18:56:13 2000 From: astewart at spawar.navy.mil (Alan Stewart) Date: Thu Aug 5 00:20:03 2004 Subject: assignment to dynamic namespace variables In-Reply-To: <3921CB1E.8A303826@planetoid.net> Message-ID: <200005162251.PAA11311@droid.nosc.mil> ~sdpm~ On 16 May 00, at 15:26, jeff wrote: >Say I was trying to assign all variables in the namespace C to values in >a hash, where the hash key should the var name. > > $C:: = $hash{$varname}; > Use a symbolic reference: ${"C::$varname"} = $hash{$varname}; ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From canetguy at home.com Wed May 17 16:35:45 2000 From: canetguy at home.com (Garrett Casey) Date: Thu Aug 5 00:20:03 2004 Subject: Perl meeting soon 2nd reminder References: <200005161412440940.8E360481@mail> Message-ID: <200005171435450072.93716FA4@mail> ~sdpm~ Just wanted to remind you that our next Perl Mongers meeting is tonight at 7:00. The location of the meeting and directions can be found at http://SanDiego.pm.org. The primary group discussion will be about Advanced Data Structures using References (made easy:). Be sure to bring your code and bios! See you tonight! -Garrett Casey 858 720 1789 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From comeaujr at sd.conexant.com Thu May 18 13:23:52 2000 From: comeaujr at sd.conexant.com (John R. Comeau) Date: Thu Aug 5 00:20:03 2004 Subject: assuring that all subroutines are defined Message-ID: <200005181823.LAA23668@pirr.sd.conexant.com> ~sdpm~ I asked a couple of people about this at the SDPM meeting last night. The question is how you can be certain that all subroutines called by your program actually exist. That is, I'd like a way to find out if any subroutines are undefined as soon as the program starts to run instead of waiting until much later when the subroutine is actually called to find out. I know this presents somewhat of a problem since new subroutines can be eval'ed into existence like the following: my $sub_definition = 'sub mysub {print "hello\n"}'; eval $sub_definition; So it would be difficult for the Perl compiler to know beforehand whether a given subroutine will exist at the time it's called. But disregarding this, is there some way to make Perl check that all subroutines are defined? By the way, neither 'use strict' nor 'perl -w' guards against undefined subroutines. -John ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rkleeman at neta.com Thu May 18 13:55:31 2000 From: rkleeman at neta.com (Bobby Kleemann) Date: Thu Aug 5 00:20:03 2004 Subject: assuring that all subroutines are defined In-Reply-To: <200005181823.LAA23668@pirr.sd.conexant.com> Message-ID: ~sdpm~ On Thu, 18 May 2000, John R. Comeau wrote: > ~sdpm~ > I asked a couple of people about this at the SDPM meeting last night. > The question is how you can be certain that all subroutines called by > your program actually exist. That is, I'd like a way to find out if > any subroutines are undefined as soon as the program starts to run > instead of waiting until much later when the subroutine is actually > called to find out. > > I know this presents somewhat of a problem since new subroutines can > be eval'ed into existence like the following: > > my $sub_definition = 'sub mysub {print "hello\n"}'; > eval $sub_definition; > > So it would be difficult for the Perl compiler to know beforehand > whether a given subroutine will exist at the time it's called. > > But disregarding this, is there some way to make Perl check that all > subroutines are defined? > > By the way, neither 'use strict' nor 'perl -w' guards against > undefined subroutines. Actually, I think use strict will protect you in a very limited sense (my memory is a little hazy on this, so you'll have to experiment to see if I'm completely correct). Strict will say something when you try to do my_sub $param, @params; and it hasn't seen or imported something like sub my_sub { ... } but if you put parens or & before your subroutine call it won't say anything: &my_sub($param, @params); But to answer your original question, I think you can do defined on a subroutine name: http://www.perl.com/pub/doc/manual/html/pod/perlfunc/defined.html You may also use defined() to check whether a subroutine exists, by saying defined &func without parentheses. _ _ _ Bobby Kleemann http://www.neta.com/~rkleeman/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From robertl1 at home.com Fri May 19 16:09:36 2000 From: robertl1 at home.com (Bob La Quey) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML Message-ID: <3.0.6.32.20000519140936.01b4bc90@mail.dt1.sdca.home.com> ~sdpm~ Hi perlmongers, I have some code and would be interested in seeing what others are up to as well. So what's up. Bob La Quey BTW, is there a FAQ or archive for this list? ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From tdarugar at velocigen.com Fri May 19 16:37:10 2000 From: tdarugar at velocigen.com (Parand T. Darugar) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML References: <3.0.6.32.20000519140936.01b4bc90@mail.dt1.sdca.home.com> Message-ID: <3925B406.FE16524A@velocigen.com> ~sdpm~ Dear Bob, > I have some code and would be interested in seeing what others > are up to as well. Check out: http://www-4.ibm.com/software/developer/library/xml-perl/ and http://www.velocigen.com/~tdarugar/talks/ For some of my stuff on XML. We use XML and Perl extensively here, so I'm definitely interested in the topic. Best, Parand Tony Darugar tdarugar@velocigen.com 858-622-1164 High Performance Perl Server Pages 858-622-0303 fax VelociGen XML Server http://www.velocigen.com/ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From robertl1 at home.com Fri May 19 17:18:59 2000 From: robertl1 at home.com (Bob La Quey) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML Message-ID: <3.0.6.32.20000519151859.00987200@mail.dt1.sdca.home.com> ~sdpm~ At 02:37 PM 5/19/00 -0700, you wrote: >~sdpm~ >Dear Bob, > >> I have some code and would be interested in seeing what others >> are up to as well. > > Check out: >http://www-4.ibm.com/software/developer/library/xml-perl/ > > and >http://www.velocigen.com/~tdarugar/talks/ > > For some of my stuff on XML. We use XML and Perl extensively >here, so I'm definitely interested in the topic. > >Best, > >Parand Tony Darugar tdarugar@velocigen.com Kool, Here is a little ditty I wrote for xml.com http://www.xml.com/pub/1999/11/sml/index.html But why don't we post a little code up here so we can have some fun and games. After all there is "more than one way to do it" so I suspect we can have some amusing arguments if not downright flamefests and religious wars. I'll kick it off. This is some code I presented at the Linux Programmers Study Group (LPSG) about a year ago. The LPSG is an offshoot of the Kernel-Panic Linux Users Group (KPLUG). LPSG meets twice a month here in San Diego at the San Diego County of Education facilty. See http://www.kernel-panic.org/lpsg/ for details. We also have an active mailing list. Here is some Perl code that uses the XML::Parser module to do (surprise) parse XML. #!/usr/bin/perl use XML::Parser; my $source_filename=shift; my $count=0; ################################################################################### # Supporting data structures and subroutines for parser ################################################################################### #set up specifics of my xml handlers %tags = ( ); # start_handler pushs tag on tag_stack, end_handler pops tag off tag_stack @tag_stack=(); $sp=1; #handlers for xml parser events sub init_handler() { my($p) = @_; print("Starting XML parsing\n"); } sub final_handler() { my($p) = @_; print("End of XML parsing\n"); 10; } sub start_handler() { my($p, $tag) = @_; $tag_stack[++$sp]=$tag; indent(); print("<",$tag,">\n"); } sub end_handler() { my($p, $tag) = @_; indent(); print("\n"); $sp--; } sub char_handler() { my($p, $el) = @_; my $current_tag=$tag_stack[$sp]; indent(); print("char_handler, current tag <",$current_tag, "> data element = \"", $el,"\"\n"); } #default_handler should never be invoked sub default_handler() { my($p, $el) = @_; if($el =~ /\w/) { # only print lines containing something other than whitespace print("default_handler ", $p, " for ", $el," ord = ", ord($el), "\n"); } } sub spaces() { my ($deep) = @_; $deep = 4*$deep; $spaces = ' ' x $deep; print($spaces); } sub indent() { &spaces($sp-1); } ################################################################################### # The parser ################################################################################### my $parser = new XML::Parser(ErrorContext => 2); $parser->setHandlers( Init => \&init_handler, Start => \&start_handler, Char => \&char_handler, End => \&end_handler, Final => \&final_handler); $parser->parsefile($source_filename); ################################################################################### Discussion: Examine the code the last few lines of code. The program 1) Instantiates an instance of the XML parser my $parser = new ... 2) Tells the parser what hanndlers to use when the parser generates an event. $parser->setHandlers( ... 3) Does the actual parsing $parser->parsefile($source_filename); perldoc XML::Parser lists among other things the Events (see HANDLERS) that the parser generates. You may associate any subroutine you want as the handler of an event. Some important Events are: 1) Init generated just before the parsing starts 2) Final generated just after succesfull parsing stops. parse returns what this returns. 3) Start generated when an XML start tag is recognized 4) End generated when an XML end tag is recognized 5) Char generated when a non-mark up string is recognized There are other Events but these will do for the purposes of this tutorial. The subroutines defined here as event handlers are just intended to print out the tags and node contents as a tutorial exercise. Actual applications would use these handlers to do something more substantial, e.g. generate HTML, or put data into a database, etc. Next we will look at using this Perl script to actually parse some simple XML. (See next post) ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From robertl1 at home.com Fri May 19 17:23:35 2000 From: robertl1 at home.com (Bob La Quey) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML Message-ID: <3.0.6.32.20000519152335.0098acc0@mail.dt1.sdca.home.com> ~sdpm~ In the previous post I supplied code for a simple parser written in using XML::Parser. Now let's run it on the file test.xml defined as:

Hello World Why not? xxx zzzz Keep on trying. yyyyy

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Invoke the XML::Parser with simple handlers for Init, Start, End, Final (i.e. leave out the Char handler) >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> %./xmltool0.pl test.xml Starting XML parsing

End of XML parsing % % Now suppose there is an error in the XML e.g a mismatched tag test1.xml

Hello World Why not? Keep on trying. huh

The parser produces Starting XML parsing

huh

==^ mismatched tag at line 7, column 3, byte 106:
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Now Add the handler for Char >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> %./xmltool.pl test.xml Starting XML parsing char_handler, current tag data element = " " char_handler, current tag data element = " " char_handler, current tag data element = " "

char_handler, current tag

data element = " Hello World " char_handler, current tag

data element = " " char_handler, current tag

data element = " " char_handler, current tag data element = " Why not?" char_handler, current tag

data element = " xxx" char_handler, current tag

data element = " " char_handler, current tag

data element = " zzzz " char_handler, current tag data element = " Keep on trying." char_handler, current tag

data element = " yyyyy " char_handler, current tag

data element = " " char_handler, current tag

data element = " "

char_handler, current tag data element = " " End of XML parsing % The Char event is called each time a string which is not a tag is recognized. Note strings are terminated (or started) by either tags or line feeds. A line feed generates a Char event. Ok, that will do till we get some feed back. Then I wiil provide some motivation for using XML (or others can jump in) and show some more useful examples of things you can do. Come folks let's get it on. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From taa0 at cris.com Fri May 19 18:08:06 2000 From: taa0 at cris.com (taa0@cris.com) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML References: <3.0.6.32.20000519140936.01b4bc90@mail.dt1.sdca.home.com> Message-ID: <3925C956.2D3078DE@cris.com> ~sdpm~ I like XML::Simple from CPAN. Less work than using XML::Parser by itself. Tom Adams Bob La Quey wrote: > ~sdpm~ > Hi perlmongers, > > I have some code and would be interested in seeing what others > are up to as well. > > So what's up. > > Bob La Quey > > BTW, is there a FAQ or archive for this list? > > ~sdpm~ > > The posting address is: san-diego-pm-list@hfb.pm.org > > List requests should be sent to: majordomo@hfb.pm.org > > If you ever want to remove yourself from this mailing list, > you can send mail to with the following > command in the body of your email message: > > unsubscribe san-diego-pm-list > > If you ever need to get in contact with the owner of the list, > (if you have trouble unsubscribing, or have questions about the > list itself) send email to . > This is the general rule for most mailing lists when you need > to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From taa0 at cris.com Sat May 20 00:23:03 2000 From: taa0 at cris.com (taa0@cris.com) Date: Thu Aug 5 00:20:03 2004 Subject: Any interest in Perl and XML References: <3.0.6.32.20000519140936.01b4bc90@mail.dt1.sdca.home.com> <3.0.6.32.20000519185003.01915a80@mail.dt1.sdca.home.com> Message-ID: <39262137.5F3943E4@cris.com> Bob La Quey wrote: > > > How about showing us some exmple code. I did this stuff about a year ago > as a learning exercise. I don't recall if XML::Simple was available then. > Is is a SAX interface? Not a SAX interface. Here's an example: -------------- next part -------------- #!/usr/local/bin/perl -w use XML::Simple; my $in; while() { $in .= $_; } my $config = XMLin($in); my $category = ${$config}{'category'}; print "category is $category\n"; my $fruithash = ${$config}{'fruit'}; foreach my $key (keys %$fruithash) { print "\t$key:\n"; my $pair = ${$fruithash}{$key}; foreach my $attrib (keys %$pair) { print "\t\t$attrib is ${$pair}{$attrib}\n"; } } __END__ ]> citrus orange orange lemon yellow lime green From rlssdpm at schnapp.org Sat May 20 11:28:38 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:03 2004 Subject: https? Message-ID: <200005201623.MAA05733@happyfunball.pm.org> ~sdpm~ Does anyone know whether PERL modules exist that will support interaction with secure web servers, i.e., https protocol? I've used HTTP::Request, and it apparently doesn't support the secure servers. Does this require licensed software? ...Russ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From robertl1 at home.com Sat May 20 11:56:23 2000 From: robertl1 at home.com (Bob La Quey) Date: Thu Aug 5 00:20:03 2004 Subject: Some XML urls for PerlMongers Message-ID: <3.0.6.32.20000520095623.01af4c20@mail.dt1.sdca.home.com> ~sdpm~ Perhaps it would be better to back up a little and to provide some reference material for those PerlMongers who are new to XML. So here goes: Common XML (All the XML you really need) http://www.egroups.com/files/sml-dev/Work/cxmlspec420.txt Why you want to use a simple XML subset like Common XML. http://www.xml.com/pub/1999/11/sml/index.html XMLmongering with Perl modules: http://www.cpan.org/modules/by-module/XML/perl-xml-modules.html The Perl XML FAQ: http://www.perlxml.com/faq/perl-xml-faq.html The best portal for XML: http://www.xml.com/pub. Two good mailing lists: The SML-DEV list is devoted to Simplifying Markup Languages: http://www.egroups.com/group/sml-dev The XML-DEV list is an older XML list on which all of the XML big guns are to be found banging away at each other: To subscribe, mailto:majordomo@xml.org&BODY=subscribe%20xml-dev List archives are available at http://xml.org/archives/xml-dev/ The W3C standard recommendation in all of its gory glory: http://www.w3.org/TR/REC-xml Forward, ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From taa0 at cris.com Sat May 20 12:17:44 2000 From: taa0 at cris.com (taa0@cris.com) Date: Thu Aug 5 00:20:03 2004 Subject: https? References: <200005201623.MAA05733@happyfunball.pm.org> Message-ID: <3926C8B8.73A770B6@cris.com> ~sdpm~ Try out http://search.cpan.org On the left side of the page under "CPAN Search:" is a pull-down menu. If you choose "Module" from the menu and search for "https" you'll get a list of 4 modules. Repeat the procedure using "Documentation" from the menu and you'll get one more module. Tom Adams Russ Schnapp wrote: > ~sdpm~ > Does anyone know whether PERL modules exist that will support > interaction with secure web servers, i.e., https protocol? > > I've used HTTP::Request, and it apparently doesn't support the > secure servers. Does this require licensed software? > > ...Russ > ~sdpm~ > > The posting address is: san-diego-pm-list@hfb.pm.org > > List requests should be sent to: majordomo@hfb.pm.org > > If you ever want to remove yourself from this mailing list, > you can send mail to with the following > command in the body of your email message: > > unsubscribe san-diego-pm-list > > If you ever need to get in contact with the owner of the list, > (if you have trouble unsubscribing, or have questions about the > list itself) send email to . > This is the general rule for most mailing lists when you need > to contact a human. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From joel at cts.com Sat May 20 12:16:00 2000 From: joel at cts.com (Joel Fentin) Date: Thu Aug 5 00:20:03 2004 Subject: Windoz 95 - perl - mysql Message-ID: <3.0.4.32.20000520101600.007b5db0@crash.cts.com> ~sdpm~ I have perl 5.6.0 installed in the windoz 95 laptop and it works. I have mysql installed and it works. I want them to play together. I was able to download and install DBI. I have been unable to install DBD::mysql. Here is some of what I have done in this quest: 1. I connected to my service provider. I shelled to DOS and typed PPM. The cursor changed to PPM>. I tried the following and more. PPM> query dbd PPM> query DBD PPM> query dbd::mysql PPM> query DBD::mysql PPM> search dbd PPM> search DBD PPM> search dbd::mysql PPM> search DBD::mysql PPM> search dbd* PPM> search dbd:: PPM> search dbd-mysql None of this got me anything. 2. I went into cpan and found: Msql-Mysql-modules-1.2214.readme Msql-Mysql-modules-1.2214.gz 3. These I downloaded 4. I read the readme. 5. Per the readme, on the DOS command line I typed: ppm install http://www.perl.com/CPAN-local/authors/id/JWIED/DBD-mysql-1.2212.x 86.ppd 6. I got this message: syntax error at line 1, col 0, byte 0 at C:perl/site/lib/soap/parser.pm line 73 7. I went into parser.pm. Line 73 reads: $Self->_create_parser()->parsestring($soap_bar); I am in over my head. ========================== At this point, I have no idea what lessons I should be picking up along the way. A. Does anyone out there have this going? B. If I never get DBD::mysql installed, should I try DBD::obdc? C. Or should I try a different (open source/free) relational database? D. If so, which? -- Joel Fentin tel: 760-749-8863 FAX: 760-749-8864 email: joel@cts.com web: http://efm.simplenet.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From todd.rockhold at ontogen.com Sat May 20 13:11:33 2000 From: todd.rockhold at ontogen.com (Todd Rockhold) Date: Thu Aug 5 00:20:03 2004 Subject: Windoz 95 - perl - mysql Message-ID: <00May20.111931pdt.118083@gateway.ontogen.com> ~sdpm~ Joel Fentin wrote about trying to install DBD::mysql. Sorry, I don't have an answer, but have another question. The "soap" part of the directory path bothers me a little bit. Is DBD::mysql trying to use Simple Object Access Protocol (another morsel from Sir Bill of Redmond)? If so, there may be a problem if you also need PerlEx (if I remember correctly, this is a costly item). PerlEx supports SOAP but I don't know if that's the only way. See http://www.activestate.com/press/releases/PerlExSoap.htm http://www.microsoft.com/presspass/press/2000/Apr00/SoapUpdatePR.asp SOAP is pretty new. In the software business we know what that can mean. Joel, I suspect that you got your stuff from Active State. They have a mailing list like this one. To sign up (maybe you will get a greater number of educated eyeballs looking at the problem) look at the bottom of the page at http://www.activestate.com/pdk/ ---------------------------------------------------------------------------- --------------- [deletia] > 5. Per the readme, on the DOS command line I typed: > ppm install > http://www.perl.com/CPAN-local/authors/id/JWIED/DBD-mysql-1.2212.x86.ppd > > 6. I got this message: > syntax error at line 1, col 0, byte 0 at > C:perl/site/lib/soap/parser.pm line 73 > [deletia] ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Sat May 20 13:48:15 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:03 2004 Subject: Windoz 95 - perl - mysql References: <00May20.111931pdt.118083@gateway.ontogen.com> Message-ID: <3926DDEF.C41F55DA@velocigen.com> ~sdpm~ Todd Rockhold wrote: > Is DBD::mysql trying to use > Simple Object Access Protocol (another morsel from Sir Bill of Redmond)? > Actually, no. PPM is trying to use SOAP to connect to the Active State repository. The parser it refers to is trying to read the result XML from a SOAP request. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Sat May 20 22:32:05 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:03 2004 Subject: https? Message-ID: <200005210326.XAA07507@happyfunball.pm.org> ~sdpm~ Thanks, Tom. I came across a mention of Crypt-SSLeay, which appears to provide enough SSL infrastructure to support https. ...Russ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From cabney at cyberpass.net Tue May 23 14:36:29 2000 From: cabney at cyberpass.net (C. Abney) Date: Thu Aug 5 00:20:03 2004 Subject: Windoz 95 - perl - mysql In-Reply-To: <00May20.111931pdt.118083@gateway.ontogen.com> Message-ID: ~sdpm~ On Sat, 20 May 2000, Todd Rockhold wrote: > Joel Fentin wrote about trying to install DBD::mysql. Sorry, I don't have [snippage] > SOAP is pretty new. In the software business we know what that can mean. Just to fan the flames a little (and nobody does that like TheRegister ): http://www.theregister.co.uk/000522-000019.html Is ActiveState working with MS to push this new extension they've embraced? CA -- Einstein himself said that God doesn't roll dice. But he was wrong. And in fact, anyone who has played role-playing games knows that God probably had to roll quite a few dice to come up with a character like Einstein. -- Larry Wall C. Abney ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From jeff at planetoid.net Thu May 25 18:52:39 2000 From: jeff at planetoid.net (jeff) Date: Thu Aug 5 00:20:03 2004 Subject: load testing tools for perl cgi forms Message-ID: <392DBCC6.1EB42ED5@planetoid.net> ~sdpm~ Can anyone recommend web resources or tools for doing LOAD TESTING of perl cgi scripts? I'm looking for something that would simulate a load on my form database submissions so I can verify concurrent access and updates to the db. I'm new at load testing and validation so any tips would be helpful. -- Jeff Saenz jeff@planetoid.net ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Thu May 25 20:11:29 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:03 2004 Subject: Lists Message-ID: <392DCF41.4936C12C@sdsc.edu> Hey all, Could anyone tell me what the easiest way to sort through this list would be. What I have is a log file that looks like this: 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 So for instance, I want to select the most current lines (the last three). Split them into there respective variables $Date $Time $Host $ftpput $ftpget $pingloss $pingavg Then loop them through a table to display the results on a webpage. Thanks for your help, Steve -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000525/1fb75f1b/smeier.vcf From rforgey at alumni.caltech.edu Thu May 25 20:57:36 2000 From: rforgey at alumni.caltech.edu (Bob Forgey) Date: Thu Aug 5 00:20:03 2004 Subject: Lists In-Reply-To: <392DCF41.4936C12C@sdsc.edu> References: <392DCF41.4936C12C@sdsc.edu> Message-ID: <14637.54846.11770.835666@red> ~sdpm~ Two ways, seems to me: 1) Reorder the date to go from most signficant to least significant (don't forget to zero pad the days and months): 5/25/2000 -> 2000/05/25 then append the time (already in this format), and then alphabetically sort: 2000/05/25:17:28:37 HostA 2250.16 2136.20 0 0 2000/05/25:17:28:52 HostB 905.77 928.76 0 0 2000/05/25:17:29:11 HostC 3632.60 3300.78 0 0 2000/05/25:18:28:37 HostA 2250.16 2136.20 0 0 2000/05/25:18:28:52 HostB 905.77 928.76 0 0 2000/05/25:18:29:11 HostC 3632.60 3300.78 0 0 See below for an example. Then undo the transformation to make it pretty again. 2) Use Time::Local.pm to convert the date/time to time in seconds, then sort numerically. Use localtime() to reverse the transformation. Bob >>>>> "Steve" == Steve Meier writes: Steve> Hey all, Steve> Could anyone tell me what the easiest way to sort through this list Steve> would be. What I have is a log file that looks like this: Steve> 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 Steve> 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 Steve> 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 Steve> 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 Steve> 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 Steve> 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 Steve> So for instance, I want to select the most current lines (the last Steve> three). Steve> Split them into there respective variables $Date $Time $Host $ftpput Steve> $ftpget $pingloss $pingavg Steve> Then loop them through a table to display the results on a webpage. Steve> Thanks for your help, --------------------------------------------------------------------------------- while() { ($Date, $Time, $Host, $ftpput, $ftpget, $pingloss, $pingavg) = split(' ', $_); ($mo, $day, $yr) = split('/', $Date); $nline = sprintf("%04d/%02d/%02d:%s %s %s %s %s %s\n", $yr, $mo, $day, $Time, $Host, $ftpput, $ftpget, $pingloss, $pingavg); push(@nlines, $nline); } print sort(@nlines), "\n"; __DATA__ 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Thu May 25 21:33:32 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:03 2004 Subject: Lists In-Reply-To: <392DCF41.4936C12C@sdsc.edu>; from smeier@sdsc.edu on Thu, May 25, 2000 at 06:11:29PM -0700 References: <392DCF41.4936C12C@sdsc.edu> Message-ID: <20000525193332.C18286@securityarchitects.com> ~sdpm~ if your logs are sorted by date and you just want to extract the last 3 lines you can do smth like: @ARGV = '/path/to/logfile'; undef $/; for ((split /\n/, <>)[-3..-1]) { my ($Date, $Time, $Host, $ftpput, $ftpget, $pingloss, $pingavg) = split; print "$Date $Time $Host yadda yadda\n"; } the above code is very memory inefficient so it might not work well for big log files. check out this webpages: http://www.perl.com/CPAN-local/doc/manual/html/pod/perlsyn.html http://www.perl.com/CPAN-local/doc/manual/html/pod/perlfunc/split.html http://www.perl.com/CPAN-local/doc/manual/html/pod/perlfunc/sort.html finally here is an excellent paper on sorting: http://www.perl.com/CPAN-local/doc/FMTEYEWTK/sort.html cheers. On Thu, May 25, 2000 at 06:11:29PM -0700, Steve Meier wrote: > > Hey all, > > Could anyone tell me what the easiest way to sort through this list > would be. What I have is a log file that looks like this: > > 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 > 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 > 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 > 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 > 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 > 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 > > So for instance, I want to select the most current lines (the last > three). > > Split them into there respective variables $Date $Time $Host $ftpput > $ftpget $pingloss $pingavg > > Then loop them through a table to display the results on a webpage. > > Thanks for your help, > > Steve Content-Description: Card for Steve Meier ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From cabney at cyberpass.net Fri May 26 16:59:09 2000 From: cabney at cyberpass.net (C. Abney) Date: Thu Aug 5 00:20:03 2004 Subject: Lists In-Reply-To: <392DCF41.4936C12C@sdsc.edu> Message-ID: ~sdpm~ Oh, ick. To do this correctly is complicated, I think... On Thu, 25 May 2000, Steve Meier wrote: > 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 > 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 > 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 > 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 > 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 > 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 A schwartzian transform (named after its inventor, Tom Christiansen) is what you need.) Wish I could bang one out for you... > So for instance, I want to select the most current lines (the last > three). can I just order them in descending order for date, ascending hostname, and descending comm data? > Split them into there respective variables $Date $Time $Host $ftpput > $ftpget $pingloss $pingavg sure... > Then loop them through a table to display the results on a webpage. #! /usr/bin/perl -w # there must be better tweaks to this # It's not tested code, and there's some baggage... I wish I could # say it's a schwartzian transform, but... wtf is it?? # prolly don't need to sort on anything past the hostname... while (<>) { chomp; $line = $_; ($d,$t,$h,$p,$g,$l,$a) = split / +/,$line; ($m,$d,$y) = split '\/', $d; ($hr,$min,$s) = split ':', $t; $m = sprintf("%02d", $m); $d = sprintf("%02d", $d); $y = sprintf("%04d", $y); $t = sprintf("%02d:%02d:%02d", $hr,$min,$s); @tmp = ($line,$m,$d,$y,$t,$h,$p,$g,$l,$a); push @elems, [@tmp]; } @elems = sort { $b->[3] <=> $a->[3] || $b->[1] <=> $a->[1] || $b->[2] <=> $a->[2] || $b->[4] cmp $a->[4] || uc($a->[5]) cmp uc($b->[5]) || $b->[6] <=> $a->[6] || $b->[7] <=> $a->[7] || $b->[8] <=> $a->[8] || $b->[9] <=> $a->[9] } @elems; print "$_->[0]\n" for (@elems); output: (0)[2218]$ ./1-sort_log.plx < data 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 (0)[2218]$ cat data 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 I'll let you work out the html formatting CA -- Einstein himself said that God doesn't roll dice. But he was wrong. And in fact, anyone who has played role-playing games knows that God probably had to roll quite a few dice to come up with a character like Einstein. -- Larry Wall C. Abney ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Fri May 26 09:33:44 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:03 2004 Subject: Lists References: <392DCF41.4936C12C@sdsc.edu> Message-ID: <392E8B48.30F80FB0@velocigen.com> ~sdpm~ In the spirit of TIMTOWTDI and webbishness: print qq{\n}; print qq{}; print qq{}; print qq{\n}; open (FILE, "in.txt") or die "didn't open file"; my @lines = ()[-3..-1]; foreach my $line (@lines) { my ($Date, $Time, $Host, $ftpput, $ftpget, $pingloss, $pingavg) = split " ", $line; print qq{}; print qq{}; print qq{\n}; } close FILE; print qq{
DateTimeHostftpputftpgetpinglosspingavg
$Date$Time$Host$ftpput$ftpget$pingloss$pingavg
\n};
I'm not sure if this is less a memory hog than Eugene's response, but it also assumes that the file is the standard append-the-last-one-to-the-end format. Check out http://www.globalspin.com/list_test.vep to see it in action. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From adms1 at cts.com Fri May 26 10:20:55 2000 From: adms1 at cts.com (adms1) Date: Thu Aug 5 00:20:03 2004 Subject: Perl Mongers Information Message-ID: <200005260820550445.48B3EB99@smtp.cts.com> ~sdpm~ Howdy Everyone! Well, the DNS has been changed to point SanDiego.pm.org to our new server donated by Michael DeVicariis. Thanks Mike! For everyone who has shell accounts, you now can refer to the server as SanDiego.pm.org. Yippee! I sincerely want to thank Bruce Timberlake for all the work he has done on the server to get it up and running. You are the man!! ## ## Next meeting at MP3.com ## All right everyone; here is your opportunity to here about some POWER PERL! I got a call from MP3.com a while back ago and they want to host our June meeting. I think it will be very fun and enlightening. I am sure everyone has heard about MP3.com and knows how popular they are, but did you know that they majority of their system is written in Perl? Did you know that they are heavy into mod_perl with the Apache server? Oh, and by the way, they also use mySQL. So here you have nearly a billion-dollar corporation using the same tools that any one of us would use to put up a little we page. How do they do it? How do they manage/operate such a large system using Perl, mod_perl, Apache, mySQL, etc.? Well, WE ARE GOING TO FIND OUT! Our next meeting is June 21st at 7:00. Location: MP3.com (I will be providing maps and directions next week). Not only is there going to be food, drinks, and MP3.com prizes/giveaways - but their engineers will be talking to us about how they use Perl (and friends) on such a large scale. Also, just think of the personal networking you could do after the presentations! EVERYONE SHOULD ATTEND THIS MEETING. Please take some time to lock up June 21, 7:00pm on your calendars. Also, invite people you work with or anyone you think may have an interest. The location where we are meeting can easily hold a couple hundred people. Because this will be a pretty large meeting, I need everyone who is planning on attending to RSVP. You can reply to the mailing list, email me at canetguy@home.com, or call me at 858-720-1789. The more accurate numbers we get on who will be attending, the easier it will be to order food. I am currently talking with some folks over at MP3.com and more information about the meeting will be available as soon as I get it. Again, if you know of anyone who has been thinking about becoming a Perl Monger, or would be interested in the meeting should be invited :) There are currently 60 of us San Diego Perl Mongers. I am hoping we can get 100-150 people to show for the meeting (see, it also serves as a membership drive:). I will be contacting local companies and other organization that may be harvesting Perl programmers. Also, messages will be sent out throughout the Perl community. If you have any contacts I should know about - don't hold back. ### ### I am leaving for Las Vegas in 1 hour. I will be there until Sunday night. If you need to get in contact with me, call my house 858-720-1789 and leave a message or buzz my cell phone at 619-417-2136. -Garrett Casey ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Fri May 26 12:43:04 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:03 2004 Subject: Lists In-Reply-To: <392E8B48.30F80FB0@velocigen.com>; from chris@velocigen.com on Fri, May 26, 2000 at 07:33:44AM -0700 References: <392DCF41.4936C12C@sdsc.edu> <392E8B48.30F80FB0@velocigen.com> Message-ID: <20000526104304.E18286@securityarchitects.com> ~sdpm~ > my @lines = ()[-3..-1]; > > I'm not sure if this is less a memory hog than Eugene's response, but it > also assumes that the file is the standard > append-the-last-one-to-the-end format. Check out > http://www.globalspin.com/list_test.vep to see it in action. it is just as bad :-) ()[-3..-1] expression will read the contents of the whole file into memory, take the last 3 lines and throw away the rest. check this out: bash-2.03$ ls -l /usr/share/dict/words -r--r--r-- 2 root bin 2486893 Mar 14 14:26 /usr/share/dict/words bash-2.03$ perl bench.pl USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND eugene 9198 0.0 1.1 336 1428 p1 SN+ 10:20AM 0:00.06 perl bench.pl USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND eugene 9198 0.0 10.5 12732 13720 p1 SN+ 10:20AM 0:02.66 perl bench.pl ^^^^^ (ouch!) Elapsed time: 2.845168 estimated memory used (rss2-rss): 13720 - 1428 -> ~12 Megs bash-2.03$ perl bench2.pl USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND eugene 8870 0.0 1.1 336 1428 p1 SN+ 10:20AM 0:00.06 perl bench2.p USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND eugene 8870 0.0 1.1 400 1452 p1 SN+ 10:20AM 0:01.96 perl bench2.p Elapsed time: 2.072702 ^^^^^^^^ second version is way way more memory efficient and is even 30% faster estimated memory used (rss2-rss): 1452 - 1428 -> 24 bytes ;-) bash-2.03$ cat bench.pl #!/usr/bin/perl -wl use Time::HiRes qw(gettimeofday tv_interval); @ARGV = '/usr/share/dict/words'; my $t0 = [gettimeofday]; print qx/ps aux -p $$/; # bench.pl contains this line my @last_3_lines = (<>)[-3..-1]; =comment while bench2.pl uses (still very slow but at least it's memory efficient) push @last_3_lines, scalar <>, scalar <>, scalar <>; while(<>) { shift @last_3_lines; push @last_3_lines, $_; } =cut print qx/ps aux -p $$/; my $elapsed = tv_interval($t0, [gettimeofday]); print "Elapsed time: $elapsed\n"; if you want speed + memory efficiency you would need to use the algorithm tail is using (map file into memory (reduce I/O, increase speed) and then start counting \n): f ((start = mmap(NULL, (size_t)size, PROT_READ, MAP_PRIVATE, fileno(fp), (off_t)0)) == (caddr_t)-1) return (1); p = start + size - 1; if (style == RBYTES && off < size) size = off; /* Last char is special, ignore whether newline or not. */ for (llen = 1; --size; ++llen) if (*--p == '\n') { WR(p + 1, llen); llen = 0; if (style == RLINES && !--off) { ++p; break; } } if (llen) WR(p, llen); if (munmap(start, (size_t)sbp->st_size)) ierr(); cheers. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From cabney at cyberpass.net Sat May 27 19:52:38 2000 From: cabney at cyberpass.net (C. Abney) Date: Thu Aug 5 00:20:04 2004 Subject: Lists Message-ID: ~sdpm~ Heheh, Bob and I came up with this (and here's your ST): perl -e 'for (map {$_->[0]} sort {$a->[3]<=>$b->[3]||$a->[1]<=>$b->[1]||$a->[2]<=>$b->[2]||$a->[4]<=>$b->[4]||$a->[5]<=>$b->[5]||$a->[6]<=>$b->[6]} map {[$_,split /[\/\s+:]/]} (<>)) {print};' < data (0)[0105]$ cat data 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 17:28:52 HostB 905.77 928.76 0 0 5/25/2000 17:29:11 HostC 3632.60 3300.78 0 0 5/25/2000 18:28:37 HostA 2250.16 2136.20 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:28:52 HostB 905.77 928.76 0 0 5/25/2000 18:29:11 HostC 3632.60 3300.78 0 0 (0)[0105]$ CA -- Einstein himself said that God doesn't roll dice. But he was wrong. And in fact, anyone who has played role-playing games knows that God probably had to roll quite a few dice to come up with a character like Einstein. -- Larry Wall C. Abney ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From cabney at cyberpass.net Sat May 27 22:08:28 2000 From: cabney at cyberpass.net (C. Abney) Date: Thu Aug 5 00:20:04 2004 Subject: Lists (HUMOR) Message-ID: ~sdpm~ Well... I thought it was pretty funny. Thought I'd put Eugene's stuff in there. And someone might even think it's useful, even if it is a joke (0)[0318]$ ln -s sail fail (0)[0318]$ cat sail #! /usr/bin/perl -w # Sorts/tails monitor logs ascending, by timestamp, where log has format: # 5/25/2000 17:28:37 HostA 2250.16 2136.20 0 0 # Changes behavior according to how it is called use strict; my $name = $0; $name =~ s/^.*?([^\/]+)$/$1/; my $numlines; if ($#ARGV == 1) { $numlines = shift; } else { $numlines = 10; } my $file = shift or die usage(); open DATA, "< $file" or die "could not open $file: $!"; my @log = ; close DATA or die "could not close $file: $!"; # How to check this is a number? if ( @log < $numlines ) { $numlines = @log; } $numlines = -$numlines; if ($name eq "sail") { @log = map {$_->[0]} sort { $a->[3] <=> $b->[3] || $a->[1] <=> $b->[1] || $a->[2] <=> $b->[2] || $a->[4] <=> $b->[4] || $a->[5] <=> $b->[5] || $a->[6] <=> $b->[6] } map { [$_,split /[\/\s+:]/] } @log; } print for (@log)[$numlines..-1]; sub usage { return "fail: A Fat tAIL\n", " Usage:\n\t", "fail [n] \n", "or\n", "sail: A Sorting(Slow) tAIL\n", " Usage:\n\t", "sail [n] \n"; } CA -- Einstein himself said that God doesn't roll dice. But he was wrong. And in fact, anyone who has played role-playing games knows that God probably had to roll quite a few dice to come up with a character like Einstein. -- Larry Wall C. Abney ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From cabney at cyberpass.net Sat May 27 17:20:59 2000 From: cabney at cyberpass.net (C. Abney) Date: Thu Aug 5 00:20:04 2004 Subject: v.1.0E-7 -> v.1.1E-7 update patch, was(Re: Lists (HUMOR) In-Reply-To: Message-ID: ~sdpm~ This patch will update your current version (v. 1.0E-7) of sail(TM) to the current alpha release (v. 1.1E-7). The special transmogrification features are still unavailable to users of windows... We don't expect this to happen in the forseeable future because the windows we have seen are opaque, but also because all the windows we have are broken and vandals reported in the DC area seem intent on breaking all the windows they can find (to wild cheers of the street mob!) Industrial Glass Repair and Shinola Conglomerate Corp., Inc. is reported to be acquiring a solution for their new improved Bullet Proof(TM) windows, the "Not Glass Windows, Stupid!" product of which some not so bullet proof releases have been made. Snickering fools in the back of the room at the press release implied it to be a Symbolic Gesture to Old Technology(TM), but it says Innovation 15 times right on the shrink wrap, so who are we to argue? Anyway, this version adds Enhanced Technology to Sail, including: o Obscure tortuous references, mostly to Schwartzian Transforms, o Obligatory self-aggrandizement, in the form of references to ourself, announcements, and speaking of ourself in the third person, o The illusion of stability: third person plural product release announcements (hmm, schizo can hardly be considered stable, or?) o The illusion of continued support: We may even fire up our revision control software on this baby, o Actual mathematically correct comments, o Kewl C-like flow control statements. o References to kewl RPGs, and expanded character classes (oh wait, maybe in the next release, but it looks good there next to 'RPG'...) License: HonorLeft License. This license grants you the right to read and use this software for your personal or corporate use under the restrictions of the honor system. This is a particularly restrictive and draconian copyright because it requires you to be honest with yourself -- possibly the most difficult task known to man. If you stab your neighbor in the back, you have no honor left. Since you have already read this email you have already agreed to these terms and I own you. heheheh. Here ya go: just do a 'patch sail patch' (updates for the symlinked 'fail' binary are available. Just send a cashiers check, two dead creeping charlies, and a self-addressed, stamped envelope to the above email address. The two dead creeping charlies are for my buddy, Tom Waits) patch: -8<---------------------------------------------- 1a2,3 > # CCAbney20000527 > # $Id:$ 13,17c15 < if ($#ARGV == 1) { < $numlines = shift; < } else { < $numlines = 10; < } --- > $numlines = ($#ARGV == 1) ? shift : 10; 28c26 < # How to check this is a number? --- > # How to check this is a integer? 34a33 > # Stonehenge magic (A level 5 spell) -8<---------------------------------------------- CA -- Einstein himself said that God doesn't roll dice. But he was wrong. And in fact, anyone who has played role-playing games knows that God probably had to roll quite a few dice to come up with a character like Einstein. -- Larry Wall C. Abney ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Mon May 29 20:25:14 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: PerlMagick? Message-ID: <200005300119.VAA06978@happyfunball.pm.org> ~sdpm~ Has anyone here had any experience installing ImageMagick and its Perl interface, PerlMagick, on Windows? I successfully built ImageMagick 5.1.1, but couldn't get PerlMagick to install. (It complained of xsubpp errors.) So, I decided to try IM 5.2. Even worse. IM seems to work only if the current directory is also the IM executables's directory. Otherwise, it complains of a missing delegates file when I try to process a jpeg. Forget about trying to install PerlMagick. Suggestions? ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Mon May 29 20:51:04 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands Message-ID: <200005300146.VAA07063@happyfunball.pm.org> ~sdpm~ ...and in the same vein as my previous message: Since IM 5.1.1 seemed to work, I tried to roll my own Perl interface, albeit with just the stuff I need to do. I tried using backtick to run the various IM commands. For example, my $id = `identify image.jpg`; should get me the raw information I need, and then I would simply parse out what I want. Unfortunately, $id remains empty. $? is 16384 (0x4000), which doesn't sound good. Of course, opening piped output is just as useless. I can't be running out of memory -- my machine has 128M. Then again, I *am* using Win98. Argh! ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 07:08:25 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands In-Reply-To: <200005300146.VAA07063@happyfunball.pm.org>; from rlssdpm@schnapp.org on Mon, May 29, 2000 at 06:51:04PM -0700 References: <200005300146.VAA07063@happyfunball.pm.org> Message-ID: <20000530050824.J18286@securityarchitects.com> ~sdpm~ what do you get after running 'identify image.jpg' from a command line? how about system("identify", "image.jpg") == 0 or die "system failed: $?" does that fail too? and btw, is identify program in your path? On Mon, May 29, 2000 at 06:51:04PM -0700, Russ Schnapp wrote: > ~sdpm~ > ...and in the same vein as my previous message: Since IM 5.1.1 > seemed to work, I tried to roll my own Perl interface, albeit with just > the stuff I need to do. I tried using backtick to run the various IM > commands. For example, > > my $id = `identify image.jpg`; > > should get me the raw information I need, and then I would simply > parse out what I want. > > Unfortunately, $id remains empty. $? is 16384 (0x4000), which > doesn't sound good. > > Of course, opening piped output is just as useless. I can't be > running out of memory -- my machine has 128M. Then again, I > *am* using Win98. > > Argh! ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 07:20:39 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: PerlMagick? In-Reply-To: <200005300119.VAA06978@happyfunball.pm.org>; from rlssdpm@schnapp.org on Mon, May 29, 2000 at 06:25:14PM -0700 References: <200005300119.VAA06978@happyfunball.pm.org> Message-ID: <20000530052039.K18286@securityarchitects.com> ~sdpm~ what version of perl are you using? did you see http://www.imagemagick.org/www/perl.html ? On Mon, May 29, 2000 at 06:25:14PM -0700, Russ Schnapp wrote: > ~sdpm~ > Has anyone here had any experience installing ImageMagick and > its Perl interface, PerlMagick, on Windows? > I successfully built ImageMagick 5.1.1, but couldn't get PerlMagick > to install. (It complained of xsubpp errors.) > > So, I decided to try IM 5.2. Even worse. IM seems to work only if > the current directory is also the IM executables's directory. > Otherwise, it complains of a missing delegates file when I try to > process a jpeg. Forget about trying to install PerlMagick. > > Suggestions? ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Tue May 30 09:46:44 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands Message-ID: <200005301441.KAA10162@happyfunball.pm.org> ~sdpm~ > what do you get after running 'identify image.jpg' from a command line? It runs properly from the command line. > how about > system("identify", "image.jpg") == 0 or die "system failed: $?" > does that fail too? I assumed that if backtick and opening a pipe fail, system will undoubtedly fail, too. Yup -- I just tried it. Actually, in today's test, all three variants (backtick, pipe, system) fail without setting $? nonzero! And yet, the very same command, from the command line, works. >what version of perl are you using? I think I'm using ActivePerl version 5.20. perl -v reports binary build 522, from 11/99. > did you see http://www.imagemagick.org/www/perl.html ? Of course. > and btw, is identify program in your path? Yes, though it doesn't seem to matter whether I explicitly name the executable or fetch it via PATH. ...Russ ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From smeier at sdsc.edu Tue May 30 10:40:40 2000 From: smeier at sdsc.edu (Steve Meier) Date: Thu Aug 5 00:20:04 2004 Subject: secure login Message-ID: <3933E0F8.44A5C01@sdsc.edu> If you guys were going to use a secure FTP login, what would you use? The sites I need to connect to don't support anonymous logins. Can't use .netrc files. I wasn't sure if the NET:FTP module was good enough? Or, use Expect.pm for the login. Or other ftp programs such as ncftp, GSI ftp? Any ideas or working examples would be great! Steve -------------- next part -------------- A non-text attachment was scrubbed... Name: smeier.vcf Type: text/x-vcard Size: 220 bytes Desc: Card for Steve Meier Url : http://mail.pm.org/archives/san-diego-pm/attachments/20000530/c20ec22f/smeier.vcf From rlssdpm at schnapp.org Tue May 30 10:58:06 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: secure login Message-ID: <200005301552.LAA10626@happyfunball.pm.org> ~sdpm~ > If you guys were going to use a secure FTP login, what would you use? Net::FTP works just fine. ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 11:18:37 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: secure login In-Reply-To: <200005301552.LAA10626@happyfunball.pm.org>; from rlssdpm@schnapp.org on Tue, May 30, 2000 at 08:58:06AM -0700 References: <200005301552.LAA10626@happyfunball.pm.org> Message-ID: <20000530091837.L18286@securityarchitects.com> ~sdpm~ Net::FTP is not secure.. it sends passwords in clear i use scp (man scp) On Tue, May 30, 2000 at 08:58:06AM -0700, Russ Schnapp wrote: > ~sdpm~ > > > If you guys were going to use a secure FTP login, what would > you use? > > Net::FTP works just fine. > ~sdpm~ > > The posting address is: san-diego-pm-list@hfb.pm.org > > List requests should be sent to: majordomo@hfb.pm.org > > If you ever want to remove yourself from this mailing list, > you can send mail to with the following > command in the body of your email message: > > unsubscribe san-diego-pm-list > > If you ever need to get in contact with the owner of the list, > (if you have trouble unsubscribing, or have questions about the > list itself) send email to . > This is the general rule for most mailing lists when you need > to contact a human. > > ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 11:23:56 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands In-Reply-To: <200005301441.KAA10162@happyfunball.pm.org>; from rlssdpm@schnapp.org on Tue, May 30, 2000 at 07:46:44AM -0700 References: <200005301441.KAA10162@happyfunball.pm.org> Message-ID: <20000530092356.M18286@securityarchitects.com> ~sdpm~ > > how about > > system("identify", "image.jpg") == 0 or die "system failed: $?" > > does that fail too? > > I assumed that if backtick and opening a pipe fail, system will > undoubtedly fail, too. Yup -- I just tried it. you assumed wrong. > Actually, in today's test, all three variants (backtick, pipe, system) > fail without setting $? nonzero! And yet, the very same command, > from the command line, works. > > >what version of perl are you using? > > I think I'm using ActivePerl version 5.20. perl -v reports binary build > 522, from 11/99. > > > did you see http://www.imagemagick.org/www/perl.html ? > > Of course. so what version of perl (not activeperl version/build) are you using? according to the above webpage perl version 5.005_02 or higher is required for perlmagick to work ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Tue May 30 11:37:26 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands Message-ID: <200005301632.MAA11028@happyfunball.pm.org> ~sdpm~ > > I assumed that if backtick and opening a pipe fail, system will > > undoubtedly fail, too. Yup -- I just tried it. > > you assumed wrong. Interesting. So, you have encountered situations under which backtick or pipe fails, yet "system" works? Can you characterize that situation? It hasn't happened to me yet... > so what version of perl (not activeperl version/build) are you using? > according to the above webpage perl version 5.005_02 or higher > is required for perlmagick to work ActivePerl build 522 is 5.005_03. (Of course, the Perl version would be relevant only to the failed installation of PerlMagick, not to the failed execution of an ImageMagick command via backtick.) ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 12:35:44 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands In-Reply-To: <200005301632.MAA11028@happyfunball.pm.org>; from rlssdpm@schnapp.org on Tue, May 30, 2000 at 09:37:26AM -0700 References: <200005301632.MAA11028@happyfunball.pm.org> Message-ID: <20000530103544.N18286@securityarchitects.com> ~sdpm~ On Tue, May 30, 2000 at 09:37:26AM -0700, Russ Schnapp wrote: > ~sdpm~ > > > I assumed that if backtick and opening a pipe fail, system will > > > undoubtedly fail, too. Yup -- I just tried it. > > > > you assumed wrong. > > Interesting. So, you have encountered situations under which > backtick or pipe fails, yet "system" works? Can you characterize > that situation? It hasn't happened to me yet... Is there a difference between 'exec "echo $arg"' and 'exec "echo", $arg' ? by looking at the above two statements you are probably going to say no... i mean they look almost identical, right? but there is a difference! the latter one doesn't use the shell for executing the command and is thus considered to be secure (see perlsec for more details). My point is that there are subtle differences that you might think don't make much difference but they do. the system call that i showed didn't use the shell which i thought might make a differnce (a blind guess i must confess). quoting the perlop manpage: qx/STRING/ `STRING` A string which is (possibly) interpolated and then executed as a system command with /bin/sh or its equivalent ^^^^^^^^^^^^^^^^^^^^^^^^^ so there was a difference after all... cheers. p.s. all of the above applies to UNIX, i don't know if it's valid in a windows world) ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From rlssdpm at schnapp.org Tue May 30 12:55:42 2000 From: rlssdpm at schnapp.org (Russ Schnapp) Date: Thu Aug 5 00:20:04 2004 Subject: ActiveState and spawning commands Message-ID: <200005301750.NAA11399@happyfunball.pm.org> ~sdpm~ Okay, your point is that some invocations go thru the shell and some don't. Got it. Unfortunately, there's no difference in this case. By the way, it turns out that in the Windows world, "echo" is a built- in to the shell, not a separate executable. Anyhow, after a little more experimentation, I see that not *all* the ImageMagick executables are silent when executed via perl. It's not a size thing, either. "identify" is silent, while "convert" talks up a storm. And I've tried building ImageMagick as static executables, just to keep things simple -- no diff. Very interesting. I've got to re-install Linux on one of my machines, so I can back to a rational world! ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From khumpherys at hotmail.com Tue May 30 14:58:01 2000 From: khumpherys at hotmail.com (Ken Humpherys) Date: Thu Aug 5 00:20:04 2004 Subject: No subject Message-ID: <20000530195801.76108.qmail@hotmail.com> ~sdpm~ Greetings: Can the DBI module support a variable in the update statement? If not how can I get around this? Thanks, Ken ________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From chris at velocigen.com Tue May 30 15:18:19 2000 From: chris at velocigen.com (Chris Radcliff) Date: Thu Aug 5 00:20:04 2004 Subject: DBI and variables References: <20000530195801.76108.qmail@hotmail.com> Message-ID: <3934220B.85362394@velocigen.com> ~sdpm~ Ken Humpherys wrote: > Can the DBI module support a variable in the update statement? If not how > can I get around this? > DBI supports variables in a number of ways. If you're only using the update statement once, you can specify it in the normal Perl way: my ($f1value, $f2value, $idvalue) = (15, 20, 12); my $statement = "UPDATE blah_table SET field1 = $f1value, field2 = $f2value WHERE idfield = $idvalue"; my $sth = $dbh->prepare($statement); my $rv = $sth->execute; Alternately, if you're using the UPDATE statement many times, you can use placeholders in the statement then fill them with variables later: my $statement = "UPDATE blah_table SET field1 = ?, field2 = ? WHERE idfield = ?"; my $sth = $dbh->prepare($statement); foreach my $f1value (15..25) { my $f2value = $f1value + 5; my $idvalue = $f1value - 3; my $rv = $sth->execute($f1value, $f2value, $idvalue); } Note that DBI uses ? for placeholders, and the values have to be specified in order, one per question mark. ~chris ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From webtemp at ucsd-pps.ucsd.edu Tue May 30 15:33:38 2000 From: webtemp at ucsd-pps.ucsd.edu (Michael DeVicariis) Date: Thu Aug 5 00:20:04 2004 Subject: FW: Message-ID: <000e01bfca76$56023480$edc3ef84@pps195-237.ucsd.edu> ~sdpm~ >Can the DBI module support a variable in the update statement? If not how >can I get around this? > > Yes it can, Ken. I have a script that I wrote to do inserts into a mySQL database and it chooses the table based upon variable input from the CGI form. Michael DeVicariis Web Administrator Programmer/Analyst UCSD Auxiliary & Plant Services (858) 534-0700 ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Tue May 30 20:32:01 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: secure login In-Reply-To: <39340658.9617AA8F@sdsc.edu>; from smeier@sdsc.edu on Tue, May 30, 2000 at 11:20:08AM -0700 References: <200005301552.LAA10626@happyfunball.pm.org> <20000530091837.L18286@securityarchitects.com> <39340658.9617AA8F@sdsc.edu> Message-ID: <20000530183201.A7591@securityarchitects.com> ~sdpm~ search for dataconn: http://search.cpan.org/doc/GBARR/libnet-1.0703/Net/FTP.pm dataconn can be used with Net::FTP retr and stor methods.. see FTP.pm for more details On Tue, May 30, 2000 at 11:20:08AM -0700, Steve Meier wrote: > For in house testing I will use the Net::FTP. I know the usage looks like: > use Net::FTP; > > $ftp = Net::FTP->new("some.host.name", Debug => 0); > $ftp->login("anonymous",'me@here.there'); > $ftp->cwd("/pub"); > $ftp->get("that.file"); > $ftp->quit; > which doesn't display any stats about the transfer. What I want to do is have it > display what is going on so I can collect the transfer rate. > > I tried something like > > use Net::FTP; > > my @ftp = Net::FTP->new("some.host.name"); > foreach (@ftp) { > $ftp->login("anonymous",'me@here.there'); > $ftp->cwd("/pub"); > $ftp->get("that.file"); > $ftp->quit; > print $_; > > } > That was a shot in the dark and I knew it wouldn't work. Does anyone know how to > collect the results? > > Thanks, > > Steve ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Wed May 31 17:27:25 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: FYI Message-ID: <20000531152724.A9681@securityarchitects.com> ~sdpm~ Building Sites with Mason: http://www2.linuxjournal.com/lj-issues/issue74/4002.html ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human. From eugene at securityarchitects.com Wed May 31 17:30:57 2000 From: eugene at securityarchitects.com (Eugene Tsyrklevich) Date: Thu Aug 5 00:20:04 2004 Subject: your mail In-Reply-To: <20000530195801.76108.qmail@hotmail.com>; from khumpherys@hotmail.com on Tue, May 30, 2000 at 12:58:01PM -0700 References: <20000530195801.76108.qmail@hotmail.com> Message-ID: <20000531153057.B9681@securityarchitects.com> ~sdpm~ http://www2.linuxjournal.com/lj-issues/issue73/3970.html might be of interest to you On Tue, May 30, 2000 at 12:58:01PM -0700, Ken Humpherys wrote: > ~sdpm~ > Greetings: > > Can the DBI module support a variable in the update statement? If not how > can I get around this? > > Thanks, > > Ken ~sdpm~ The posting address is: san-diego-pm-list@hfb.pm.org List requests should be sent to: majordomo@hfb.pm.org If you ever want to remove yourself from this mailing list, you can send mail to with the following command in the body of your email message: unsubscribe san-diego-pm-list If you ever need to get in contact with the owner of the list, (if you have trouble unsubscribing, or have questions about the list itself) send email to . This is the general rule for most mailing lists when you need to contact a human.