Re: Tk.pm

2013-06-18 Thread Owen
> I have a program that needs Tk.pm. > I run perl under Ubuntu 12.04 > After configuring the Makefile 'make' gives the following error: Does not Ubuntu, Synaptic, show a perl-tk tk8.4 and tk8.4-dev Just install those might be easier. Synaptic will find any other depend

Re: how to retrieve the keys from hash in the sequence in which data is inserted

2013-04-23 Thread Owen
xHash-1.23/lib/Tie/IxHash.pm -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Date::Manip DateCalc

2013-03-29 Thread Owen
appens if you remove the ',3' from the $unparsed_date calculation? Cos I am not sure that is an argument in that Date::Calc computation. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: .profile not being read

2013-02-18 Thread Owen
, but if on a *nix system, you should read man bash to see what profiles are executed with your system and write to them accordingly -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Learning CPAN

2012-10-04 Thread Owen
les? There is spam free news group, comp.lang.perl.announce that puts out a posting every day listing a sample of about 50 modules. If you read that every day, you will get the idea of what is what. Also http://search.cpan.org/ is the home site that allows you to search for modules. -- Ow

A regex problem?

2012-08-13 Thread Owen
he results.(and not quite understanding what it does) However, it removes line feeds as well, so maybe that code is not all that good. Just wondering if this would be just as adequate in filtering "malicious code" $q1_elaborate =~ s/[`\\"|!\.\^]//g TIA -- Owen -- To unsubscribe

Re: Raspberry Pi: Beginners Web App Example

2012-08-12 Thread Owen
Linux > web server here: > > http://www.raspberryperl.com Love it. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: system command not working in different versions

2012-08-08 Thread Owen
hine it is working and in the other machine it is >> not >> working. >> >> Ex:- system("./submit_now.pl $"); >> >> can you please, tell me what is the reason? >> and as well solution. I don't know if anyone else has given this answer

Re: Test Mail

2012-08-03 Thread Owen
> I want to subscribe to this perl forum Look at the message headers... List-Subscribe: <mailto:beginners-subscr...@perl.org> -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Strange use of => ?

2012-05-11 Thread Owen
;? The "split /\./" I understand. I've looked at perldoc pack and sort of see it is taking the ip4 address, packing it up and then unpacking. But what's with these "=>" things? How is that routine meant to read? TIA Owen =

Re: Can't find string terminator

2012-05-09 Thread Owen
b/mysql > free ExData --fields-enclosed-by=\"\ --fields-terminated-by=\|\"); Count the ". One way or the other, the parser cannot find a matching " -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: XML::Mini question

2012-04-18 Thread Owen
t; my $xmlHash = $xmlDoc->toHash(); > > print Dumper($xmlHash); > > > I get the following output: > VAR1 = { > 'book' => 'Learning Perl ' > }; > > > I would have expecte to have >book' => ' Learning Perl &#

Re: WWW::Selenium click not working - CPAN install problem

2012-04-05 Thread Owen
0 > /usr/lib/perl5/vendor_perl/5.10.0/i386-linux-thread-multi > /usr/lib/perl5/vendor_perl /usr/lib/perl5/site_perl .) > at lib/Devel/REPL/Plugin/Selenium.pm line 6. > BEGIN failed--compilation aborted at lib/Devel/REPL/Plugin/Selenium.pm > line 6. Perhaps you should install that, see

Re: localtime output result

2012-04-02 Thread Owen
qw(open close); use 5.012; use Time::localtime; use File::stat; open my $fh, '<', "too0.tex"; my $modtime = ctime( stat($fh)->mtime ); say $modtime; printf "Year is %d\n", localtime->year() + 1900; = -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Transitioning from BASH to Perl

2012-03-16 Thread Owen
t; which deals with this kind of approach? Try google, search on example perl grep example perl awk example perl tr It will get you started -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: insert a . every four characters

2012-03-09 Thread Owen
ways to do that? > > > okay I answered my own question. I am wondering if there is a > different > way? > > I did: > > $it =~ s/(\S{4})/$1\./g; What is there is only, say 11 characters? Or doesn't that situation arise -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Dereferencing an array

2012-01-27 Thread Owen
cated. Any clues as to the syntax to get back the data would be appreciated TIA Owen #!/usr/bin/perl use strict; use warnings; my @lat; my @lon; my @desc; my $rest_ref; while () { my ( $lat, $lon, @rest ) = split; print &

Re: File test operator (race conditions)

2011-11-27 Thread Owen
; Thanks in advance. > > > #!/usr/bin/perl > > use strict; > use warnings; > > my $file = "sample.txt"; > > if ( -e $file ) { >     print "File exists.\n"; > } else { >     print "File does not exist.\n"; > } > > __END__

Re: how to do this in perl (from unix)

2011-09-01 Thread Owen
> from linux: >   > cut -f1,5- -d" " file |grep -v "^0" | sort -n > to_file;   <==this > line: how to achieve this in perl? Perhaps try something like system (cut -f1,5- -d" " file |grep -v "^0" | sort -n > to_file); You

Regex help

2011-05-16 Thread Owen
would love to know the correct syntax for the RE TIA Owen = #!/usr/bin/perl use strict; use warnings; while () { my $line = $_; my @line = split /,/; $line[1] =~ s /\"//g; print "$line[1]\n" if $l

Re: Help regular expression - string paring

2011-05-05 Thread Owen
> Hi there, > > Hereby I have a string parsing problem to ask. The sample strings look > like this: > > : CC02 0565 8E93 D501 0100 6273 .eb > : 6800 0500 9093 D501 0100 1400 h... > > What I am interested is the the 21st and 22nd byte value

How does this work?

2011-04-27 Thread Owen
There is a person on the Internet using this to advise his email address. perl -le "print scalar reverse qq/moc.liamg\100halbhalb/" I am intrigued as to how "001\" becomes "@" What should I be reading? TIA Owen -- To unsubscribe, e-mail: begi

Re: perl interview questions

2011-04-21 Thread Owen
e a general "IQ" type of question and any answer would do as long as you could explain it. In my mind the simplest answer would have been to randomly split the herd in two. The probability of each group of ten meeting the criteria would be almost the same? Owen -- To unsubscribe,

Alternative to goto

2011-04-13 Thread Owen Chavez
I'm writing a script for work that navigates users through a complex decision-making tree, where decisions are made based on some fairly in-depth processing of data entered by the user. The script runs really well, does exactly what we need it to do. I'm having some trouble with the humans using

Re: perl dd

2011-03-30 Thread Owen
> Thanks all!! > > Can someone tell me if you have any experience in generating files > quickly(not sparse) in unix? > > I want to generate millions of files under some directory > This will generate 1 files in less than a second. They are 0 size, so just write something into them if you don't

Re: config file modules confusion

2011-02-07 Thread Owen
ich one should > I use..? > > Config::General, Config::Simple, Config::Inifiles, just to name a > few.. I have used Config::General, its fine and easy to usse. owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: reducing decimal ouput

2010-12-06 Thread Owen
to 3 digits after decimal point $rounded = sprintf("%.3f", $number); === Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: About the perl $_ problem

2010-11-03 Thread Owen
__DATA__ >8. 1 >9. 2 >10. 3 >11. 4 >12. 5 >13. 6 >14. 7 >15. 8 > > So my problem is what the different about the two scripts .. > > Because I am the perl beginner . If the question is very simple, > please > forgive me .

Subroutine question: Placement of subroutine definitions matter?

2010-10-30 Thread Owen Chavez
uot;TEST"; &testsub1(); I'm guessing that I'm misunderstanding how Perl compiles the code. I'm reading through Learning Perl and Programming Perl but I've either missed something, or have yet to read far enough. Any explanation would be appreciated. OWEN.

Re: Directory Size

2010-10-27 Thread Owen
a directory is to calculate the total, in MB's, the size of > the files > in a particular directory folder. http://www.perlmonks.org/?node_id=168974 may help. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Disadvantages of "our" v. "my" when declaring variables

2010-10-15 Thread Owen Chavez
y around this? What are the disadvantages to using "our" in a fairly widespread manner, to avoid having to waste time going back and making the substitutions. Thanks for any input. Regards, Owen

Alternative to while ()

2010-09-29 Thread Owen Chavez
even if it is effective). Can someone nudge me in the right direction? -Owen.

Re: cgi sqlite error not able to write data in database

2010-07-23 Thread Owen
> On 07/24/2010 08:53 AM, Owen wrote: >> >>> hi, >>> it got some error while adding data into sqlite through Perl script >>> on >>> Apache ... script can able to read the file but not able to write >>> .. I >>> have set the permissi

Re: Perl stat script ... ???

2010-07-18 Thread Owen
so > am > thinking a Perl script should be the way to go then instead so I can > have it > on any UNIX's flavours. > > Any suggestion will be very much appreciated. stat? Try # perldoc -f stat and see if it finds anything for you -- Owen -- To unsubscribe, e-mail:

Re: parsing csv

2010-07-02 Thread Owen
tp://search.cpan.org/search?query=csv&mode=all http://search.cpan.org/~tmtm/Text-CSV-Simple-1.00/lib/Text/CSV/Simple.pm seems to be one that could suit you? -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: What is the best way to parse a GPX (XML) file

2010-06-16 Thread Owen
gt; Have a look at http://search.cpan.org/~andya/Geo-Gpx-0.26/lib/Geo/Gpx.pm -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: List of Available Modules ... ???

2010-06-04 Thread Owen
> Hi all, > > I know perl -V prints what are the current modules directories that > are > accessible ... but is there a way to list all the available modules > from > each directories as well? > Try this; perldoc -q "How do I find which modules are install

Re: How to move a directory to another location on the same filesystem/volume?

2010-05-23 Thread Owen
quot;} Then read all the files in A opendir( my $DB_DIR, "A" ); my @files = readdir($DB_DIR); close $DB_DIR; Then copy them across; foreach my $file(@files){copy "$file", "B/$file"}; The variable for the OS is "$^O". You need to use this the then set

sort hash with an array as the value

2010-05-11 Thread Owen
#x27;t make a separate hash of the value because of multiple values of the value http://perldoc.perl.org/perlfaq4.html#How-do-I-sort-a-hash-(optionally-by-value-instead-of-key)%3f ( http://goo.gl/Ol31 ) only shows the sorting where the hash has only a scalar. TIA Owen -- To unsubscri

say

2010-05-09 Thread Owen
t;; print LIST }". This keyword is only available when the "say" feature is enabled: see feature. =perldoc -q feature No documentation for perl FAQ keyword `feature' found Just wondering how I can featureise 'say' TIA

Re: Perl rounding errors?

2010-04-26 Thread Owen
> > Cany anyone advise me how to deal with this as I need to find a way to > round > correctly in all cases not just in cases where Perl decides it is a > good > idea to do so. :-) > > Regards, This may be of interest; http://faq.perl.org/perlfaq4.html#Does_Perl_have_a_rou -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Transparent color

2010-04-23 Thread Owen
On Fri, 23 Apr 2010 15:04:27 +0800 "CHAN, KENNETH 1 [AG/7721]" wrote: > First of all, thanks Owen, Shlomi and Shawn for your advices. > But I still can't get the line appear on the transparent circle. I am > guessing maybe there is a problem with my Perl setting or so

Re: Need help to resove..... ExtUtils-Makemaker comilation

2010-04-22 Thread Owen
including EXTERN.h Do you have EXTERN.h anywhere? Maybe try symbolically link it to the CORE directory? -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Meta: "Nice" Perl?

2010-04-22 Thread Owen
fter a while decided that some of the complaints issued weren't really worth worrying about. I hardly look at the book these days. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Transparent color

2010-04-22 Thread Owen
d drive. The background line is there when I viewed it in xview. What did you use to view the image? Owen (see below for rewritten code) > > ## Code ### > > print "Content-type: text/plain; charset-iso-8859-1\n\n"; > > > > use

Re: Newbie stuck at the first hurdle

2010-04-22 Thread Owen
s use strict use warnings;# helps in debugging my $target = "D:\testfile.txt"; open (my $NEWBIE, '<', "$target") or die "can't open $target $!\n"; my @arr = <$NEWBIE>; foreach my $line (@arr){ print "$line"; # no need for a

Re: Can't locate object method "TIEHASH" via package " Apache::Session::MySQL

2010-04-19 Thread Owen
ib/Session.pm > line 38. > > Could not create new session: Can't locate object method "TIEHASH" via > package " Apache::Session::MySQL" at /var/www/cgi-bin/lib/Session.pm > line 38 I really don't know, but the documentation shows; tie %hash, 

Re: Regex to validate user input (match any word or phrase)

2010-04-18 Thread Owen
n example only > > Any idea how to match this properly? Try one of the posix character classes.[[:class]] where class would probably be alnum (See http://perldoc.perl.org/perlre.html ) If the data base contains names like O'Rourke, then you might have to rethink your database o

Re: Incrementing letters in for loop

2010-04-12 Thread Owen
auto increments to 'z', then when the next comparison is made, it is equal to 'z' and so increments again. I suspect auto increment is different for letters and numbers > print "\n\n"; > > for(1..7){ > print " $letter "; > $letter++; > } Which goes to show that the thing after 'z' is 'aa' using the auto increment Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Pattern matching problem - Why won't this work?

2010-04-12 Thread Owen Chavez
mming Perl (3rd) and it's not entirely clear to me how to proceed with a hash. Owen On Mon, Apr 12, 2010 at 10:11 PM, Peter Scott wrote: > On Mon, 12 Apr 2010 21:06:58 -0500, Owen Chavez wrote: > > I have a pattern matching question using Perl 5.10, Windows 7. Suppose > >

Pattern matching problem - Why won't this work?

2010-04-12 Thread Owen Chavez
e second "I" although I've included the /g modifier. Can anyone tell me why? How can I accomplish this? Owen Chavez

Re: String length limits?

2010-04-12 Thread Owen
ething unwise like split// and turn you scalar > into a multi-million elements array. I have a file of 1s and 0's that is 15689303 bytes; running the program below takes about 10 seconds on reasonably fast dual core with 4 GByte of RAM ==

Re: Perl appears to be introducing whitespace when reading .txt files

2010-03-31 Thread Owen
\n"; while (<$FILETEST>) { chomp; my @words= split / /; my $nr_words = @words; print "Number of words is $nr_words and the words are\n @words\n"; } But you might want to split on white space to cope with the occasions when there is more than one space between words. You have done something that puts a space between letters when printing out. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Dereferencing hash with array value

2010-02-12 Thread Owen
how to do it (The error message ... Can't use string ("4") as an ARRAY ref while "strict refs" in use ..) should tell me something, but I'm not sure what. Where am I wrong? TIA Owen = #!/usr/bin/perl use strict; my @folders

Re: XML to RDF using O O Perl

2010-02-10 Thread Owen
f and xml threw up many results. Here is one; http://search.cpan.org/~awin/XML-Parser-Style-RDF-0.01/RDF.pm -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Need email list for Perl/Tk questions

2010-02-04 Thread Owen
> Besides this forum, does anyone know of a good Perl/Tk email > list/forum in which to ask questions about Perl/Tk? You can try comp.lang.perl.tk which is fairly quiet -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: begin

Re: listing all modules

2010-01-29 Thread Owen
ons -Tlwe 'find { wanted => sub { print canonpath $_ if /\.pm\z/ }, no_chdir => 1 }, @INC' Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Working with Excel spreadsheets

2010-01-25 Thread Owen
> What about open office spread sheets.  Can they be read by these > excel CPAN  entries? Probably not, Excel is Excel and open Office is open office However if you search CPAN for openoffice, you might find something to use, http://search.cpan.org/search?query=OpenOffice&mode=a

Re: Working with Excel spreadsheets

2010-01-25 Thread Owen
others, like Spreadsheet::DataFromExcel -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Some Date Arithmetic/Manipulation help please !!!

2010-01-22 Thread Owen
ou would be advised to look at the perl modules, Date::Calc or Date::Manip Having extracted your date, you need to get the day, month and year and then feed that into Date::Calc , eg; use Date::Calc qw(Delta_Days); $Dd = Delta_Days($year1,$month1,$day1,$year2,$month2,$day2); -- Owen

Re: How to make skip an input parameter.

2010-01-09 Thread Owen
'three' is being taken as > 2nd > input parameter and I guess white space is a default delimiter. Is > there any > special delimiter which I can use to skip an I/P parameter. I know what you are asking, and I have seen the answer by Shlomi Fish but wonder if using Getopt::S

Re: Please help me recover my Perl script.

2009-12-27 Thread Owen
>> >> What does it say in a hex editor? >> > > > # hexdump Test.pl > 000 > * > 0001090 > 0001094 I would take a guess and say don't waste anymore time on it. Put your energies in rewriting the p

Re: Please help me recover my Perl script.

2009-12-27 Thread Owen
file. See it anyway? * > > Is there a way I can convert this binary file to its initial readable > state. > What does it say in a hex editor? -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Regex problem

2009-12-26 Thread Owen
fail. unless ( $ARGV[2] =~ /^20\d{6}?/ ) { print "$ARGV[2]\tdate format is MMDD, eg 20091031\n"; } How do I get the regex to fail a 9 digit number I suppose as a work around, I could say; unless ((length($ARGV[2]) == 8) and ( $ARGV[2] =~ /^20/){fail} TIA Owen -- To unsubscri

Re: pid file issues...? HUH???

2009-12-13 Thread Owen
ot;; #extract pid from here exec "kill -9 $1" } else { exec "/path/to/myprogram" }# start program = You maybe able to adapt it for your needs. EG, delete the PID file if the program is running. Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Windoze Woez

2009-12-12 Thread Owen
se days had one liners most of which I could not get to work on W3.1 So 10 years ago I installed RH-5.2 and bingo, all the one liners started to work. The rest is history. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h..

Re: Insecure $ENV{PATH} message

2009-11-29 Thread Owen
r"} = "/usr/bin/lpr"; > > Nor do > > $ENV{"/usr/bin/lpr"} = "lpr"; > $ENV{"PATH"} = "/usr/bin/lpr"; > > Thanks for helping out. > Forget about the $ENV{} In your command, where you have lpr replace that with

Re: remove directory from @INC

2009-11-28 Thread Owen
eplaced by libssl.so.10. Can you > give me > an idea on how to solve this? > > Thank you for helping out. Well I have no idea if it will solve your problem, but try one of these; a. make a symbolic link between libssl.so.8 and libssl.so.10 b. or simply copy libssl.so.10 as lbssl.

Re: Perl CGI Incremental find

2009-11-16 Thread Owen
Or this type of stuff should be done with another language/technology? You are looking at Ajax You might want to look at CGI::Ajax it has heaps of examples Also search CPAN for Ajax for more modules -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additio

Re: Problem with function getquotaroot in IMAP::Client

2009-10-31 Thread Owen
. > > My code snippet is given below > > my %quota=$imap->getquotaroot('INBOX') || die $imap->error(); > print "Quota: $quota{'STORAGE'} \n"; Hi, Just out of interest, what permissions/ownership are assigned to the 'quota' executable

Re: yet another question

2009-10-06 Thread Owen
ogram as to who is trying to infect your machine, or trying to break in. Just try it, just do it, every one has their own preferred way of doing things -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: ||= operator

2009-08-15 Thread Owen
a; my $a = $a ||= 2; print "$a\n"; So I come to the conclusion that || and ||= are the same, but in terms of precedence, || will have the higher precedence than ||= -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Reading a list of numbers into an array

2009-07-22 Thread Owen
line (){ push (@array, $line) } print "@array\n"; __DATA__ 6754 7890 6543 -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: module for accessing MSSQL

2009-07-07 Thread Owen
> On Tue, Jul 7, 2009 at 4:36 PM, Owen wrote: >> >> >>> what's the standard module for accessing MSSQL? >>> I searched on CPAN but found a lot. >>> The program should be run on Linux, not Windows. >>> Thanks. >> >> >> >

Re: module for accessing MSSQL

2009-07-07 Thread Owen
ts of information. Alternatively, get hold of the book, Programming the Perl DBI by Alligator Descartes and Tim Bunce. -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: CGI

2009-06-09 Thread Owen
> > Hello, > >> On Mon, 2009-06-08 at 23:38 -0700, Irfan Sayed wrote: >> ____ >> From: Owen >> To: Irfan Sayed >> Cc: beginners@perl.org >> Sent: Tuesday, June 9, 2009 12:03:49 PM >> Subject: Re: CGI >> >

Re: CGI

2009-06-08 Thread Owen
script it throws me an error like > > Can't find string terminator "HI" anywhere before EOF at ./test1 line > 5. I think the HI has to aligned to the left, eg, print < Welcome to CGI scripting HI try that -- Owen -- To unsubscribe, e-mail: begin

Re: calc function's executed time

2009-06-01 Thread Owen
ldoc.perl.org/functions/times.html For millisecond resolution see DateTime::HiRes (Create DateTime objects with sub-second current time resolution) http://search.cpan.org/~jhoblitt/DateTime-HiRes-0.01/lib/DateTime/HiRes.pod -- Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Data Comparison

2009-04-18 Thread Owen
t;; > system("sleep 60"); > } > exit 0; What would the errors be? I see you are using strict, what is the output of # perl -c Does that give you any clues? Maybe just for testing, you want to try a sleep of 1 or 2 seconds? what happens if the values are in sync?

Re: Syntax query

2009-04-15 Thread Owen
uot; \" \'{print \$2}\' | cut -b 1-9 "); > > The value returned by $test2 is 0. I suspect grep and awk commands are > not > getting executed. > Is there any thing wrong in the syntax ???? You will probably need to specify the full path of grep and awk. (usr/b

RE: Reg:Regular expression

2009-04-15 Thread Owen
> > > > -Original Message----- > From: Owen [mailto:rc...@pcug.org.au] > Sent: Wednesday, April 15, 2009 3:16 PM > To: Gowri Chandra Sekhar Barla, TLS, Chennai > Subject: RE: Reg:Regular expression > >> >> >> >> -Original Message---

RE: Reg:Regular expression

2009-04-15 Thread Owen
> > Hi owen, > > Please help me in resolving errors in the following script > > open(INPUT," open(OUTPUT,">new.txt"); > $temp = \/user\/gowri\/remote2; > while ( ) { > $_ =~ s{\\/user\\/cce\\/g_tool}{$temp}; > print OUTPUT $_; > } Well, I c

RE: Reg:Regular expression

2009-04-15 Thread Owen
syntax error at example1.pl line 5, near "$str =~ s{\\/user" > > Unmatched right curly bracket at example1.pl line 5, at end of line > > Execution of example1.pl aborted due to compilation errors. Looking at your numbered script above, I cannot find $str nor /iprcc

Re: cpan Audio::File fails

2009-03-23 Thread Owen
> On Sun, Mar 22, 2009 at 8:56 PM, Owen wrote: >>> Hello >>> >>> I repeatedly run into problems when installing modules and I havent >>> yet figured out a way to consistently resolve them. >>> >>> I want to install Audio::File b

Re: cpan Audio::File fails

2009-03-22 Thread Owen
rbis::Header::PurePerl: Didn't find an ogg header - invalid > file? > > # Failed test 'Audio::File::Ogg::AudioProperties::length()' My guess is that you are missing a header file. If you are using a distribution based system, look for something like libogg-dev or/and libvorbis-d

Re: busy_handler in sqlite

2009-03-19 Thread Owen
for any help Hi, You might want to also ask on the perl-dbi users mailing list, or in the perl.dbi.users news group Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Strange regular expression

2009-03-15 Thread Owen
at it's doing. you can define matching criteria by using / ... / or | ... | or % ... % and probably a couple of others. In this case % has been used Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: I'd like to monitor a running script.

2009-03-08 Thread Owen
use strict; my $program = ""; my $status = `/bin/ps cat | /bin/grep $program`; if ( length($status) > 0 ) { sleep 30; } else { exec "the_process" }# start program owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Can docx2txt Be Installed In Windows Strawberry Perl as a Module

2009-03-08 Thread Owen
e and install it and give it permissions My guess is that for Windows, you need only take the .pl file and run it like any other perl script See the README for details Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Date::CalC

2009-03-06 Thread Owen
> } > > } > > } #End of sub > > &NewProducts(); > I am not sure what you expected, but here is a rewrite which you could look at and see how it works. Owen ===

Re: perl script on remote server

2009-03-02 Thread Owen
t back if it is there, then exits The whole process is initiated by a cron job, including the generation of the file in the first place. HTH Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: picking largest key by value..

2009-02-26 Thread Owen
ys %files) { > print "$jot $files{$jot}\n"; > } > > for my $now (keys %files) { >$max = $now if $now > $max; > } > > > print "<$max>\n"; > What happens if you put this at the top of your program use strict; use warnings; use diagnostics; ? Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

Re: Query in Perl Programming

2009-02-24 Thread Owen
ght get the idea. uninitialized errors, I guess, are mainly caused by passing an undefined value. You have to work back from the error line to then determine why the value is unititialized. Owen use strict; use warnings; use diagnostics; # provides a more verbose explanation of errors use

RE: Query in Perl Programming

2009-02-22 Thread Owen
to the first line then run perl -c What is the result? Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

RE: Query in Perl Programming

2009-02-22 Thread Owen
> > #perl -c

RE: Query in Perl Programming

2009-02-22 Thread Owen
> > Hi Owen, > > My code is as follows : > > use strict; > use warnings; > use Time::Local; > > $days1 = epoch_days('30-Jan-09'); > $days2 = epoch_days('16-Feb-09'); > > $day = $days1 - $days2; > > print "Difference: @{[$days1

RE: Query in Perl Programming

2009-02-22 Thread Owen
ove errors ? Yes Because you are not passing the integers required by your module Time::Local You are doing something wrong with your parsing or date extraction. Do you have a sample code snippet reproduces those errors and that you can post here ? Owen -- To unsubscribe, e-mail: be

Re: bash in perl

2009-02-07 Thread Owen
); > > Can You help me to write the result of 'pwd' in $x? Where is 'pwd'? You will find it in /usr/bin probably, just look Then do your system("/usr/bin") Generally though you might prefer to specify those commands earlier, eg, my $pwd = '/bin/pwd&#x

RE: Query in Perl Programming

2009-01-30 Thread Owen
> > Get the same error, when the date is set to > > my $days1 = epoch_days('30-Jan-09'); > my $days2 = epoch_days('14-Feb-2009'); > > Day '30' out of range 1..28 at ./date2.pl line 35 > > -Rajini > > > > > > >>

RE: Query in Perl Programming

2009-01-30 Thread Owen
hpcll402:/home/raji/perl>./date2.pl > Day '30' out of range 1..28 at ./date2.pl line 35 > Feb 2009 has 29 fays? Owen -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/

  1   2   3   4   >