Data::Dumper trouble

2004-02-12 Thread Jan Eden
Hi all, I want to store some complex data. My first solution made use of Storable, which worked just fine. Now I learned that neither Storable nor MLDBM are available on the machine I want to use the program on (and they cannot be made available). So I retreat to the core and use Data::Dumper t

Re: Unique file names.

2004-02-12 Thread Randy W. Sims
On 2/12/2004 9:53 PM, John McKown wrote: I have a bit of a problem and I'm wondering if there is a better solution. I have a Perl program (of course) which reads STDIN and breaks it into separate files based on a "report separator". I can construct an appropriate file name based on information i

Re: Handling error with exception

2004-02-12 Thread Randy W. Sims
On 2/12/2004 9:56 PM, Hari Fajri wrote: Do perl have handling error (exception) mechanism? for example: java use : try{...} catch{...} perl has pretty poor build-in exception handling which consists of executing some code in an eval{...} block and then check $@ to see if an error occured. There

Including files to pick up variables

2004-02-12 Thread Robin Sheat
Hey there, what is the best way of including a Perl so that the contents of it override the existing variables. For example, I have: ... my $comment = "Default\n"; my $resDir = "results"; ... if (@ARGV) { my $c = shift; $config = "testing/$c.pm"; unless (my $ret = do $config) {

Handling error with exception

2004-02-12 Thread Hari Fajri
Do perl have handling error (exception) mechanism? for example: java use : try{...} catch{...} Thanks

Unique file names.

2004-02-12 Thread John McKown
I have a bit of a problem and I'm wondering if there is a better solution. I have a Perl program (of course) which reads STDIN and breaks it into separate files based on a "report separator". I can construct an appropriate file name based on information in the "trailing" separator. I.e. I don't

RE: strings

2004-02-12 Thread Toby Stuart
> -Original Message- > From: Mark Goland [mailto:[EMAIL PROTECTED] > Sent: Friday, February 13, 2004 1:28 PM > To: [EMAIL PROTECTED] > Subject: strings > > > Hi All, > > I have a tring which contains 60 to 80 keywords, I need to > know what position a keyword is in. I need an efficint

strings

2004-02-12 Thread Mark Goland
Hi All, I have a tring which contains 60 to 80 keywords, I need to know what position a keyword is in. I need an efficint way to extra position of key words, here is how I am currently finding positions, $string="type,model,color,date"; # this is how I am currently getting position, which is n

Re: Which is better, opening and closing, or a massive file opening and a massive closing?

2004-02-12 Thread wolf blaum
For Quality purpouses, [EMAIL PROTECTED] 's mail on Wednesday 11 February 2004 22:08 may have been monitored or recorded as: Hi, > I'm still working on the script, though it is cleaning up even better, I > even have it running cleaner by dumping anything not matching some specs. > What I am try

Re: Reg. length of anonymous array

2004-02-12 Thread david
Balaji thoguluva wrote: > For clarity, I have something like this structure > > my $rhash = { > $rarray => [ ], > }; > > I would like to know the length of the anonymous array containing some > elements. the usual trick use be used: #!/usr/bin/per

Reg. length of anonymous array

2004-02-12 Thread Balaji Thoguluva
Hi, I am a novice to perl programming. I have a reference to a hash with a hash key as a reference to an anonymous array. For clarity, I have something like this structure my $rhash = { $rarray => [ ], }; I would like to know the length of

Re: can't use CPAN with Mandrake 9.2

2004-02-12 Thread Jerry M. Howell II
Understood but since I read it and had a similar issue not long ago I'll post. from the command line type urpmi perl-devel You are probably missing the header files needed by cpan. On Mon, 2004-02-09 at 20:32, Brian's Linux Box wrote: > This might be better off on a Mandrake list, but I was hopin

Re: NDS user and group query

2004-02-12 Thread Rob Dixon
Michael Weber wrote: > > I would like to create a web page that will allow users to look at my > Novell NDS tree groups and see what users are members, and look at users > to see what groups they are members of. > > I don't want to give them ConsoleOne or NWAdmin since some of them are > still look

Re: RE:help on picking up key & values

2004-02-12 Thread Rob Dixon
Ajit P Singh wrote: > > Comrades, > > > I have a function which takes up arguments as shown below: > > $str = "./place_order -t " . > "/thus/axioss/serviceID:\"" . $self->{serviceID} . "\" " . > "/thus/axioss/supplierProduct:\"" . $self->{supplierProduct} . "\" " > . > "/thus/axioss/web

NDS user and group query

2004-02-12 Thread Michael Weber
Greetings! I would like to create a web page that will allow users to look at my Novell NDS tree groups and see what users are members, and look at users to see what groups they are members of. I don't want to give them ConsoleOne or NWAdmin since some of them are still looking for the "Any" key.

RE:help on picking up key & values

2004-02-12 Thread Singh, Ajit p
Comrades, I have a function which takes up arguments as shown below: $str = "./place_order -t " . "/thus/axioss/serviceID:\"" . $self->{serviceID} . "\" " . "/thus/axioss/supplierProduct:\"" . $self->{supplierProduct} . "\" " . "/thus/axioss/web/installationTelephoneNumbe

Re: RFC - implementing callbacks

2004-02-12 Thread Wiggins d Anconia
> On Thursday 12 Feb 2004 4:19 pm, James Edward Gray II wrote: > > On Feb 12, 2004, at 9:21 AM, Gary Stainburn wrote: > > > > > The choice is, of course, yours. > > > > If you're going to tie all these things together like that though and > > keep track of everything, I think you should take Wi

Re: RFC - implementing callbacks

2004-02-12 Thread James Edward Gray II
On Feb 12, 2004, at 11:25 AM, Gary Stainburn wrote: I am aware of this and have taken on board the things you've said before. Rethinking which object performs which task will help reduce the need to loop backs. For instance having a lever drive a gantry which drives a signal eliminates the nee

Re: RFC - implementing callbacks

2004-02-12 Thread Gary Stainburn
On Thursday 12 Feb 2004 4:19 pm, James Edward Gray II wrote: > On Feb 12, 2004, at 9:21 AM, Gary Stainburn wrote: > > I can understand the point that James made, in that the update of the > > Trainset > > objects is being made by a Tk event trigger, and could therefore simply > > update the screen

Re: formatting the loop

2004-02-12 Thread James Edward Gray II
On Feb 12, 2004, at 10:06 AM, Michael S. Robeson II wrote: On Feb 11, 2004, at 2:55 PM, James Edward Gray II wrote: [snip] my @char = ( /[a-z]/ig, ( '-' ) x $len )[ 0 .. $len - 1 ]; If I may, yuck! This builds up a list of all the A-Za-z characters in the string, adds a boat load of extra

Re: RFC - implementing callbacks

2004-02-12 Thread James Edward Gray II
On Feb 12, 2004, at 9:21 AM, Gary Stainburn wrote: I can understand the point that James made, in that the update of the Trainset objects is being made by a Tk event trigger, and could therefore simply update the screen at the same time, e.g. clicking on a lever throws a signal *and* updates the

Re: formatting the loop

2004-02-12 Thread Michael S. Robeson II
On Feb 11, 2004, at 2:55 PM, James Edward Gray II wrote: [snip] my @char = ( /[a-z]/ig, ( '-' ) x $len )[ 0 .. $len - 1 ]; If I may, yuck! This builds up a list of all the A-Za-z characters in the string, adds a boat load of extra - characters, trims the whole list to the length you want

Re: RFC - implementing callbacks

2004-02-12 Thread Gary Stainburn
On Tuesday 10 Feb 2004 10:41 pm, Wiggins d Anconia wrote: > > On Feb 10, 2004, at 3:29 AM, Gary Stainburn wrote: > > > Hi folks, > > > > Hello again. > > > > [snipped history] > I hate beating a dead horse... but this discussion of your callbacks and > triggering events that are caught by a main co

Re: RFC - implementing callbacks

2004-02-12 Thread Gary Stainburn
On Wednesday 11 Feb 2004 2:54 pm, R. Joseph Newton wrote: > James Edward Gray II wrote: > > On Feb 10, 2004, at 3:29 AM, Gary Stainburn wrote: > > > Hi folks, > > > > Hello again. > > > > [snipped history] > > > > > One of the points made in the previous threads was that there should > > > be no >

Re: Maybe Stupid RegEx Question

2004-02-12 Thread James Edward Gray II
On Feb 12, 2004, at 7:34 AM, Bastian Angerstein wrote: Hi Hello. I have two strings 0x1479ee und 0x1479fe. The strings a in $var1 and $var2. if I do: if ( $var2 =~ /\Q$var1\E/) It matches. You sure about that? #!/usr/bin/perl my($var1, $var2) = ("0x1479ee", "0x1479fe"); if ($var2 =~ /\Q$v

Re: Which is better, opening and closing, or a massive file opening and a massive closing?

2004-02-12 Thread Jenda Krynicky
From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > I am wondering if it is more processor intensive to open the 42 > separate files at one time, parse the data, and then close all the > files, or if I should try to re-write the parse to open the correct > file, dump the data, and then close that file,

Maybe Stupid RegEx Question

2004-02-12 Thread Bastian Angerstein
Hi I have two strings 0x1479ee und 0x1479fe. The strings a in $var1 and $var2. if I do: if ( $var2 =~ /\Q$var1\E/) It matches. how can I match an the string and not on each sign? -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]