[28795] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 39 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jan 16 21:05:34 2007

Date: Tue, 16 Jan 2007 18:05:04 -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           Tue, 16 Jan 2007     Volume: 11 Number: 39

Today's topics:
    Re: convert Vbscript to Perl code <rvtol+news@isolution.nl>
    Re: convert Vbscript to Perl code <nospam@somewhere.com>
    Re: How do you Call a Perl subroutine with a variable n <tadmc@augustmail.com>
        I can't figure this regex out, Help please. <donot@reply.com>
    Re: I can't figure this regex out, Help please. <abigail@abigail.be>
    Re: I can't figure this regex out, Help please. <jurgenex@hotmail.com>
    Re: Map Windows from Unix <veatchla@yahoo.com>
    Re: Map Windows from Unix <spamtrap@dot-app.org>
        package mail::message anyone heard of it? <jganders@gmail.com>
    Re: Perl DBI PostgreSQL <raminoacid@gmail.com>
    Re: Perl DBI PostgreSQL <raminoacid@gmail.com>
    Re: Position in an array <rvtol+news@isolution.nl>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: Tue, 16 Jan 2007 23:41:42 +0100
From: "Dr.Ruud" <rvtol+news@isolution.nl>
Subject: Re: convert Vbscript to Perl code
Message-Id: <eojo0s.t8.1@news.isolution.nl>

Boris Skoblo schreef:

> please help me convert following VBscript code to Perl code

http://www.activestate.com/Products/Perl_Dev_Kit/more_information.plex 
"convert useful VBScript code to Perl"

-- 
Affijn, Ruud

"Gewoon is een tijger."


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

Date: Tue, 16 Jan 2007 20:05:40 -0500
From: "Thrill5" <nospam@somewhere.com>
Subject: Re: convert Vbscript to Perl code
Message-Id: <IcqdnZ4nncL56zDYnZ2dnUVZ_oCmnZ2d@comcast.com>


"Uri Guttman" <uri@stemsystems.com> wrote in message 
news:x73b6amxtp.fsf@mail.sysarch.com...
>>>>>> "WMP" == Wayne M Poe <louisREMOVE@REMOVEh4h.com> writes:
>
>  WMP> I don't spend much time in -this- forum, but who the hell are you to
>  WMP> tell me I cannot comment? You are nto a moderator, do please don't 
> quit
>  WMP> your day job.
>
> i have 5 day jobs and i can't quit any of them. all involve coding perl
> for high wages. your turn.
>
>  >> because your name is not familiar and almost of the regular helpers
>  >> are. simple.
>
>  WMP> HOW does this give them the right to voilate the very rules you 
> preach
>  WMP> to me?
>
> what are you babbling about?
>
>  >> so give it up already and go away. you are not helping with perl and
>  >> not helping with anything about this group.
>
>  WMP> Neither are you it seems. you seem to just want to keep on with your
>  WMP> clouded view of people like yourself are completely immune fro mthe
>  WMP> guidelines you hold so high.
>
> hmm, i seem to recall writing about perl here almost every day. your turn.
>
>  >> btw, tad is the primary author (with plenty of group feedback) of this
>  >> group's guidelines which are published regularly. i suggest you read
>  >> them. and then you can shut up.
>
>  WMP> I dont care if hes the Queen of England, NO ONE has the right to 
> just
>  WMP> berate people the way he does. I have read the guidelines, as I do 
> for
>  WMP> any ng or forum I visit and I'm still puzzeled why hes allowed to
>  WMP> frequently voilate his -own- rules. Should that not reflect on him?
>
> who? don't use dangling pronouns. didn't your third grade english
> teacher learn you that?
>
>  >> no assumptions. you have not mentioned perl once in this thread.
>  >> guilty as charged!!
>
>  WMP> Neither have you, but I forgot, it's ok for you and your aligned to 
> go
>  WMP> against what ever you preach.
>
> hmm, check google please. not only do i help here, i give talks to my
> local pm, at yapc, at oscon (here and across the pond), publish perl
> articles, publish popular perl modules on cpan and i also am writing a
> module to stop global warming. your turn!
>
>  >> > Just because someone helps doesn't give them the right to be an ass.
>  >> > Just because someone doesnt participate, doesn't mean they cant
>  >> > voice a comment. Only a communistic-type mind-set might feel
>  >> > otherwise.
>  >>
>  >> nope. no helping means no commenting on how others help. you
>  >> lose. BZZZZZTTT. next contestant please!
>
>  WMP> Funny how you like to self proclaim your self as a game shwo host 
> when
>  WMP> we are supposed to be same level discussing. Just shows oddles about
>  WMP> whats wrong with your general view of things, imho.
>
> that is an incorrect answer. the correct answer is that i help people
> (like you!) with perl issues. i don't charge for it here. yous gets
> whats youse pays for. and i pays a lot!
>
>  >> BTW you are being mocked and you are even more foolish for attempting
>  >> to keep this going. i won't let go until you shut up and leave. keep
>  >> proving how foolish you are by continuing. your choice.
>
>  WMP> Unlike you for continually preaching rule and regulations and then
>  WMP> reminding how you and others are free to break them whenever you 
> damn
>  WMP> please. Yes, I'm the one who appears foolish...
>
> what rules have i violated? please quote the guidelines which i have
> broken. have you read the guidelines? i ask specific perl questions of
> posters in order to help them. so did tad. those are part of teaching
> perl. your turn!
>
>  >> or you can actually make some comments about perl for a change. i
>  >> doubt that will happen. prove me wrong. i triple dog dare ya!!
>
>  WMP> But you dont have to, right? As for Perl, I make use of it quit a 
> bit my
>  WMP> every day programming needs, at work and at home.
>
> wow. i never use perl for my baking or cooking.
>
> please don't try to defend vronans. you will look as foolish as he does.
>
> uri
>
> -- 
>
Not as foolish as you have made yourself out to be.

Scott 




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

Date: Tue, 16 Jan 2007 05:59:53 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: How do you Call a Perl subroutine with a variable name?
Message-Id: <slrneqpfhp.bs3.tadmc@tadmc30.august.net>

Wayne M. Poe <louisREMOVE@REMOVEh4h.com> wrote:
> Tad McClellan wrote:
>> Wayne M. Poe <louisREMOVE@REMOVEh4h.com> wrote:


>> > What I really dislike here is the approach you (and others
>> > sometimes) take in conveying this information.
>>
>>
>> Then simply post a few more forgeries to "even it out".
>
> I didn't forge anything. 


Message-ID: <1165296208.732891.75320@16g2000cwy.googlegroups.com>


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


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

Date: Wed, 17 Jan 2007 00:41:19 GMT
From: Charlie White <donot@reply.com>
Subject: I can't figure this regex out, Help please.
Message-Id: <Xns98BAA9C412DBCcactuna@208.49.82.220>

I have a string that has been excaped with "\" 

eg.   "This is charlie\'s company\'s  May\\June"

what I would like to end up with is 

"This is charlie's company's  May\June"

Everything I tried drops out the \ between MayJune also

Anyhelp in this regex would be gratefully appreciated

CW



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

Date: 17 Jan 2007 00:50:25 GMT
From: Abigail <abigail@abigail.be>
Subject: Re: I can't figure this regex out, Help please.
Message-Id: <slrneqqsmb.74f.abigail@alexandra.abigail.be>

Charlie White (donot@reply.com) wrote on MMMMDCCCLXXXVII September
MCMXCIII in <URL:news:Xns98BAA9C412DBCcactuna@208.49.82.220>:
::  I have a string that has been excaped with "\" 
::  
::  eg.   "This is charlie\'s company\'s  May\\June"
::  
::  what I would like to end up with is 
::  
::  "This is charlie's company's  May\June"
::  
::  Everything I tried drops out the \ between MayJune also

Well, what have you tried? You *do* know that there's just one backslash
between May and June in the given string, don't you?

Perhaps you want this:

    $_ = "This is charlie\'s company\'s  May\\June";
    s/\\'/'/g;
    print

which prints:

    This is charlie's company's  May\June


Or are the double quotes part of the string, and you want to unescape
all the backslashes? Something like:

    $_ = q {"This is charlie\'s company\'s  May\\\\June"};
    s/\\(.)/$1/g;
    print;

which prints:

    "This is charlie's company's  May\June"


I hope you realize that in:

    $_ = "This is charlie\'s company\'s  May\\June";

there's only one backslash between May and June.


Abigail
-- 
               split // => '"';
${"@_"} = "/"; split // => eval join "+" => 1 .. 7;
*{"@_"} = sub {foreach (sort keys %_)  {print "$_ $_{$_} "}};
%{"@_"} = %_ = (Just => another => Perl => Hacker); &{%{%_}};


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

Date: Wed, 17 Jan 2007 01:11:36 GMT
From: "Jürgen Exner" <jurgenex@hotmail.com>
Subject: Re: I can't figure this regex out, Help please.
Message-Id: <cJerh.10030$My1.3270@trndny03>

Charlie White wrote:
> I have a string that has been excaped with "\"
>
> eg.   "This is charlie\'s company\'s  May\\June"
>
> what I would like to end up with is
>
> "This is charlie's company's  May\June"

Sorry for being dense, but those two strings are identical already.

jue 




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

Date: Tue, 16 Jan 2007 20:00:28 -0600
From: l v <veatchla@yahoo.com>
Subject: Re: Map Windows from Unix
Message-Id: <12qr0pq5osdmf7c@news.supernews.com>

Tuhin wrote:
> Hi Mark,

Install Perl on your PC along with Net::FTP and Net::Telnet or Net::SSH 
or use Putty or Putty's plink.


> 
> Here is what I am doing now:
> 
> Step 1. Every month, I receive data on CD from another department.
> Step 2. Using Windows Explorer, I copy those data in the appropriate
> directory on a remote Unix server.

use Net::FTP to ftp your CD data files to the appropriate unix directories.

> Step 3. Then I connect to the Unix server using Exceed On Demand.
> Step 4. Then I run a Perl script (which I wrote on the Unix server) to
> generate some reports from those data.

use Net::Telnet or Net::SSH or plink to connect to your unix server and 
remotely run the unix Perl script to generate your reports.

> 
> Now, here is what I am trying to do:
> 
> I like to do Step 1 while sitting on the Unix server so that when I
> will run my Perl script, first it will prompt to copy the data from the
> CD. CD ROM is connected with the PC.
> 
> Since I am new in the Perl world, my idea is, sitting on the Unix
> server if I can open the Windows Explorer (or any file selection dialog
> box that will display the directory structure of the PC), then I will
> be able to copy the data from the CD using my Perl script.
> 
> Thanks for your time.
> 
> Tuhin
> 


-- 

Len


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

Date: Tue, 16 Jan 2007 21:01:18 -0500
From: Sherm Pendley <spamtrap@dot-app.org>
Subject: Re: Map Windows from Unix
Message-Id: <m2ejpu76oh.fsf@Sherm-Pendleys-Computer.local>

"Tuhin" <minhaztuhin@hotmail.com> writes:

> Hi Sherm,
>
> I clicked on "Start a new topic", filled out the message area and
> clicked on post message. I don't know what I did wrong. But I found
> that the way you replied my topic initiates fighting using slang words
> which is unfortunate. I subscribed in this group with the intention of
> learning some thing because I believed that you guys are expart. But
> unfortunately your reply discouraged me to continue in this group. You
> are expert, but dont pretend that every one is in your level. Please
> stop fighting. I am unsubcsribing now.
>
> Tuhin

I have no idea what your problem is, but I haven't said a single word to
you. My posts in this thread have all been replies to Mr. DeFaria, not to
you.

Note that one problem with Mr. DeFaria's HTML-formatted posts is that he
is using HTML <blockquote> elements instead of the usenet standard ">"s
to show quoted material - that's one reason you're finding it difficult
to discern who's replying to whom, but that's not my fault. I'm the one
who's asking him to please stop doing that.

sherm--

-- 
Web Hosting by West Virginians, for West Virginians: http://wv-www.net
Cocoa programming in Perl: http://camelbones.sourceforge.net


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

Date: 16 Jan 2007 16:13:00 -0800
From: "jga.socal" <jganders@gmail.com>
Subject: package mail::message anyone heard of it?
Message-Id: <1168992778.115756.85920@a75g2000cwd.googlegroups.com>

Hi.
I'm trying to use some perl code in the app found at (
http://www.jmbfree.com/software/ts ) 'incoming.pl'.
It calls out:
use Mail::Message and
use Mail::Address

Unfortunately there is no Message.pm in any of the libs in my perl
dist.
The closest I get is /usr/lib/perl5/site_perl/5.8.7/Mail which has a
Mailer.pm and an Address.pm
Can anyone know where a mail package containing a Message.pm can be
found?
Thanx.



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

Date: 16 Jan 2007 16:48:31 -0800
From: "raminoacid" <raminoacid@gmail.com>
Subject: Re: Perl DBI PostgreSQL
Message-Id: <1168994911.324939.150240@l53g2000cwa.googlegroups.com>

Hi and thanks for the follow up. Here is the connection code:

#
# connection and DB constants
use constant USERNAME => 'toto;
use constant PASSWORD => '123pwd321';
use constant DB_CONNECTION => "dbi:Pg:dbname=dbTestpp/webroot/files/";

#...

# connect to the database and extract the records matching the query
my $dbh = DBI->connect(DB_CONNECTION, USERNAME, PASSWORD, {'RaiseError'
=> 1});

#...




gf wrote:
> raminoacid wrote:
> > Hi,
> >
> > I'm using Perl's DBI package to connect to a PostgreSQL database.
> > Everything works fine except the annoying  DEBUG: output for each DB
> > operation. This is not the same as tracing since the later can be
> > disabled. For instance, the following output can be seen in my
> > terminal:
> [...]
> > Is there anyway to disable this. I need to parse my output file and I'd
> > like to have a light-weight file rather a file with lots of garbage.
>
> Please show a sample of your connect() call, along with all the
> parameters used.



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

Date: 16 Jan 2007 16:56:03 -0800
From: "raminoacid" <raminoacid@gmail.com>
Subject: Re: Perl DBI PostgreSQL
Message-Id: <1168995362.353681.243870@q2g2000cwa.googlegroups.com>

Sorry, the copy&paste was messed up, here is the corrected code:

# connection and DB constants
use constant USERNAME => 'toto;
use constant PASSWORD => '123pwd321';
use constant DB_CONNECTION =>
"dbi:Pg:dbname=dbTest;host=localhost;port=8889";

#...

# connect to the database and extract the records matching the query
my $dbh = DBI->connect(DB_CONNECTION, USERNAME, PASSWORD, {'RaiseError'
=> 1});

Thanks.



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

Date: Tue, 16 Jan 2007 23:53:15 +0100
From: "Dr.Ruud" <rvtol+news@isolution.nl>
Subject: Re: Position in an array
Message-Id: <eojojn.1fg.1@news.isolution.nl>

anno4000@radom.zrz.tu-berlin.de schreef:

>  $_ is often aliased to
> another variable.  If it is when this code is called, "$_ = $test[$x]"
> will assign the value to an unrelated variable somewhere in the
> program, which can be a hard-to-find bug.


news:eoe8jb.1k8.1@news.isolution.nl
"how to solidly spoil the value of $_"
:)

-- 
Affijn, Ruud

"Gewoon is een tijger."



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

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


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