[29898] in Perl-Users-Digest
Perl-Users Digest, Issue: 1141 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Dec 24 09:09:38 2007
Date: Mon, 24 Dec 2007 06:09:02 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Mon, 24 Dec 2007 Volume: 11 Number: 1141
Today's topics:
Re: "Program Working" web page ? <wheeledBobNOSPAM@yahoo.com>
Re: CMD in WinXP <goldtech@worldpost.com>
Re: CMD in WinXP <jurgenex@hotmail.com>
Re: Regex to remove non printable characters <jurgenex@hotmail.com>
Re: Which editor for Perl hacking are you using <RedGrittyBrick@SpamWeary.foo>
Re: Which editor for Perl hacking are you using <bik.mido@tiscalinet.it>
Win32::OLE ADO Table Field names <goldtech@worldpost.com>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Sun, 23 Dec 2007 15:32:07 GMT
From: still just me <wheeledBobNOSPAM@yahoo.com>
Subject: Re: "Program Working" web page ?
Message-Id: <jqvsm3l68hcviririvkn7mjsgs8ia72a5n@4ax.com>
On Sat, 22 Dec 2007 23:43:05 +0100, Gunnar Hjalmarsson
<noreply@gunnar.cc> wrote:
>
>You may want to check out this article:
>http://www.stonehenge.com/merlyn/LinuxMag/col39.html
Thanks Gunnar, looks promising...
------------------------------
Date: Sun, 23 Dec 2007 10:00:43 -0800 (PST)
From: goldtech <goldtech@worldpost.com>
Subject: Re: CMD in WinXP
Message-Id: <bb7bc89b-cda9-4510-9014-1226caeb49bd@s8g2000prg.googlegroups.com>
> ...command prompt window scrolls real slow....
Are you saying that perl scripts process slowly? Either you have other
processes running that are gobbling up resources and slowing you down
and/or your script maybe needs to be reworked to make it faster.
------------------------------
Date: Sun, 23 Dec 2007 19:58:01 GMT
From: Jürgen Exner <jurgenex@hotmail.com>
Subject: Re: CMD in WinXP
Message-Id: <b4ftm3pmhd4j9iangskife9t4urq61tfac@4ax.com>
goldtech <goldtech@worldpost.com> wrote:
>> ...command prompt window scrolls real slow....
>
>Are you saying that perl scripts process slowly? Either you have other
>processes running that are gobbling up resources and slowing you down
>and/or your script maybe needs to be reworked to make it faster.
Well, no. I agree with the OP, print()ing to the terminal in Windows is
quite slow. I am not sure if it's the actual scrolling of the text or if
printing even small text pieces involves a large overhead and thus slows
down the process. Either way it can be somewhat annoying.
I believe one workaround may be to do your own buffering and print()ing the
data in larger chunks instead of in many small pieces.
jue
------------------------------
Date: Sun, 23 Dec 2007 17:45:07 GMT
From: Jürgen Exner <jurgenex@hotmail.com>
Subject: Re: Regex to remove non printable characters
Message-Id: <p57tm3dqffe88o8gcepbn8fbbh7tnat5dl@4ax.com>
"John W. Krahn" <krahnj@telus.net> wrote:
>Larry <dontmewithme@got.it> wrote:
>> is this fine?
>>
>> $input =~ tr/\x80-\xFF//d;
>
>Your subject line says you want a regex. The tr/// operator doesn't use regular expressions.
Good point. However, if you are splitting hairs, then let's be accurate:
Regular expressions match a string but they never remove anything as
requested by the OP. Therefore taking literally the OPs question is
non-sensical in the first place.
And he still didn't tell us if he wanted to remove non-ASCII or
non-printable, two very different categories which have no relationship with
each other whatsoever.
jue
------------------------------
Date: Sun, 23 Dec 2007 14:44:19 +0000
From: RedGrittyBrick <RedGrittyBrick@SpamWeary.foo>
Subject: Re: Which editor for Perl hacking are you using
Message-Id: <Q4KdnfFHkuvO6fPanZ2dnUVZ8h2dnZ2d@bt.com>
Keith Keller wrote:
> On 2007-12-22, Randal L. Schwartz <merlyn@stonehenge.com> wrote:
>> That's like saying "Please - no platform wars, but which is better,
>> XBOX 360, PS/3, or Wii?". Can't be done. :)
>
> I prefer the PS/2. The Model 80 was pretty nice. ;-)
Hmm,
http://members.chello.at/theodor.lauppert/games/ascii.htm
------------------------------
Date: Sun, 23 Dec 2007 16:48:04 +0100
From: Michele Dondi <bik.mido@tiscalinet.it>
Subject: Re: Which editor for Perl hacking are you using
Message-Id: <ao0tm390nd0al0pmj5cumpe46u3brev845@4ax.com>
On Sat, 22 Dec 2007 02:35:58 +0100, Joost Diepenmaat <joost@zeekat.nl>
wrote:
>> That's like saying "Please - no platform wars, but which is better,
>> XBOX 360, PS/3, or Wii?". Can't be done. :)
>
>I think the replies so far have been very polite and informative. In any
Ok: my editor is better than yours. Yours sucks. An impolite and
uninformative answer, eventually! :)
Michele
--
{$_=pack'B8'x25,unpack'A8'x32,$a^=sub{pop^pop}->(map substr
(($a||=join'',map--$|x$_,(unpack'w',unpack'u','G^<R<Y]*YB='
.'KYU;*EVH[.FHF2W+#"\Z*5TI/ER<Z`S(G.DZZ9OX0Z')=~/./g)x2,$_,
256),7,249);s/[^\w,]/ /g;$ \=/^J/?$/:"\r";print,redo}#JAPH,
------------------------------
Date: Sun, 23 Dec 2007 10:15:38 -0800 (PST)
From: goldtech <goldtech@worldpost.com>
Subject: Win32::OLE ADO Table Field names
Message-Id: <166274f9-9151-4de5-9992-5b8293dfc1e3@s48g2000hss.googlegroups.com>
Hi,
Given code below, I can get tables and run SQL on an ms-access db -
this works well. But, I want to get the field names per each column
of a table. I'm sure there's an ADO way of doing it. Help appreciated.
Thanks.
Question: How do I get the field names of each column of a table?
#!/usr/bin/perl
# use strict;
use Win32::OLE();
$Win32::OLE::Warn=2;
my $conn = Win32::OLE->new("ADODB.Connection");
my $db = 'C:\Folder4\usa.mdb';
$conn->Open('Provider = Microsoft.Jet.OLEDB.4.0; Data Source='.$db);
my $rs= $conn->OpenSchema(20);
$rs->MoveFirst();
while(!$rs->{EOF}){
my $tn= $rs->Fields(2)->Value;
if (grep /^$tn$/i, 'States') {
my $rowcount = $conn->Execute("SELECT COUNT(*) AS ROW_COUNT
FROM " .$tn.'"');
print "$tn : ".$rowcount->Fields('ROW_COUNT')->Value."\n";
}
$rs->MoveNext;
}
__END__
states : 51
DC included.
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V11 Issue 1141
***************************************