Re: DBI

2006-08-02 Thread Bjørge Solli
On Tuesday 01 August 2006 17:04, Greg Sabino Mullane wrote: use strict; use DBI; $sth-bind_param( 1, \$insertid, SQL_INT); #insertid from other insertion $sth-bind_param( 2, \$ap, SQL_DOUBLE); You need to tell DBI to import the SQL type constants. This is done by replacing 'use

book to learn perl

2006-08-02 Thread Sayed, Irfan \(Irfan\)
Hi, Can anybody plz guide , which is the best book to learn perl. some good names plz Regards Irfan.

Re: book to learn perl

2006-08-02 Thread Mathew Snyder
Sayed, Irfan (Irfan) wrote: Hi, Can anybody plz guide , which is the best book to learn perl. some good names plz Regards Irfan. Learning Perl from www.oreilly.com is a good primer. Mathew Snyder -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail:

RE: book to learn perl

2006-08-02 Thread Ankam, Ramesh Babu
O'REILLY's Learning Perl By Randal Schwartz, Tom Christiansen Larry Wall; Second Edition, July 1997. This is one of the best books to learn perl. Thanks Regards, RameshAnkam Unisys Unisys Global Services - India Bangalore Tel: 91-80-4159 4411 Mobile: 919986458344 Mail: [EMAIL PROTECTED]

Re: book to learn perl

2006-08-02 Thread Bjørge Solli
On Wednesday 02 August 2006 12:14, Ankam, Ramesh Babu wrote: Irfan wrote: Can anybody plz guide , which is the best book to learn perl. O'REILLY's Learning Perl By Randal Schwartz, Tom Christiansen Larry Wall; Second Edition, July 1997. Buy the fourth edition, july 2005 instead. I too

Multiple line parameters in parameter file

2006-08-02 Thread Jerry Rocteur
Hi, I've just searched the web and tried the archives but I'm not in luck I'm reading a parameter file: PARAM=value PARAM1=value2 Etc. and this works great, but all of a sudden...I need multiple lines.. For example: login=logname password=password ftpfiles=/var/opt/file1, /var/opt/file2,

Re: Modify a line after occurance of a specific word?

2006-08-02 Thread Rob Dixon
The Other1 wrote: I process a set of files and end up with a hash with server, administrator pairs. I need to read in another file and modify (or add if it does not exist) a line containing the word administrator following the line with the server name. Hash pairs: Server1 Bob Server2

Re: Multiple line parameters in parameter file

2006-08-02 Thread Rob Dixon
Jerry Rocteur wrote: I've just searched the web and tried the archives but I'm not in luck I'm reading a parameter file: PARAM=value PARAM1=value2 Etc. and this works great, but all of a sudden...I need multiple lines.. For example: login=logname password=password

Multiple line parameters in parameter file

2006-08-02 Thread Jerry Rocteur
Hi, I've just searched the web and tried the archives but that is down at the moment. I'm reading a parameter file: PARAM=value PARAM1=value2 Etc. and this works great, but all of a sudden...I need multiple lines.. For example: login=logname password=password ftpfiles=/var/opt/file1,

regex matching multiple occurances

2006-08-02 Thread Paul Beckett
I would like to match multiple occurrences of the same pattern: /\'([a-z0-9]{32})\'/ This could appear 0 - to many times on a line. I need the actual text match, not just the occurrence frequency. Any suggestions as to how I could catch these would be appreciated. Cheers, Paul -- To

How to download file with the MIME type Download'

2006-08-02 Thread Anish Kumar K.
Hi How can I download a file any type image,wav or document in download format if I have the http://location with perl Say the location file is present can be http://www.abc.com/a.gif http://www.abc.com/a.doc print Content-Type:application/x-download\n; print

RE: Multiple line parameters in parameter file

2006-08-02 Thread Ryan Frantz
-Original Message- From: Jerry Rocteur [mailto:[EMAIL PROTECTED] Sent: Wednesday, August 02, 2006 4:59 AM To: beginners@perl.org Subject: Multiple line parameters in parameter file Hi, I've just searched the web and tried the archives but that is down at the moment. I'm

Re: regex matching multiple occurances

2006-08-02 Thread Rob Dixon
Paul Beckett wrote: I would like to match multiple occurrences of the same pattern: /\'([a-z0-9]{32})\'/ This could appear 0 - to many times on a line. I need the actual text match, not just the occurrence frequency. Any suggestions as to how I could catch these would be appreciated. Hello

Re: Modify a line after occurance of a specific word?

2006-08-02 Thread The Other1
John said: This appears to do what you want: [SNIP] Rob said: This problem interested me and here is my offer of an alternative solution to John's, which works in normal line input mode instead of paragraph mode. Take your pick! [SNIP] WOW! Thanks guys. Nice coding on both parts. I

RE: if-clause again

2006-08-02 Thread Charles K. Clarkson
Dr. Claus-Peter Becke wrote: : first of all a question without respect to my problem. what does : HTH mean? Hope that helps or, sometimes here in Texas it means hotter than Hell. : i would like of having returned a string value as printed by : print @row. That is in a loop. There may

file help

2006-08-02 Thread Sayed, Irfan \(Irfan\)
Hi All, Following is the code which i am executing but i am not getting the output of command my $out = system($cmd); into the file. Plz help. Regards Irfan. #/usr/atria/bin/Perl -w use strict; use warnings; my $CT = /usr/atria/bin/cleartool; my @vob_list = `$CT lsvob -s`; my

match and grab

2006-08-02 Thread Tim Wolak
Hello all, I am writing a script to monitor a file and if a line is matched write it to a file, then grab the IP address from that line and write it to another file. As I'm ok on working with the files, I need a little help as to how to get the IP address out of the line of text into a variable

Re: Multiple line parameters in parameter file

2006-08-02 Thread Rob Dixon
Jerry Rocteur wrote: On Wed, Aug 02, 2006 at 12:15:23PM +0100, Rob Dixon wrote: Jerry Rocteur wrote: Hi Jerry I started writing this in a single pass, but its a lot easier if you take two passes - effectively converting from multi-line parameters to single-line ones. I assume you're not

Re: file help

2006-08-02 Thread Rob Dixon
Sayed, Irfan (Irfan) wrote: Hi All, Following is the code which i am executing but i am not getting the output of command my $out = system($cmd); into the file. Plz help. Regards Irfan. #/usr/atria/bin/Perl -w use strict; use warnings; my $CT = /usr/atria/bin/cleartool; my

Re: match and grab

2006-08-02 Thread Rob Dixon
Tim Wolak wrote: I am writing a script to monitor a file and if a line is matched write it to a file, then grab the IP address from that line and write it to another file. As I'm ok on working with the files, I need a little help as to how to get the IP address out of the line of text into

Re: match and grab

2006-08-02 Thread Rob Dixon
Tim Wolak wrote: On Wed, 2006-08-02 at 17:05 +0100, Rob Dixon wrote: Tim Wolak wrote: I am writing a script to monitor a file and if a line is matched write it to a file, then grab the IP address from that line and write it to another file. As I'm ok on working with the files, I need a

Re: file help

2006-08-02 Thread John W. Krahn
Sayed, Irfan (Irfan) wrote: Hi All, Hello, Following is the code which i am executing but i am not getting the output of command my $out = system($cmd); into the file. #/usr/atria/bin/Perl -w use strict; use warnings; my $CT = /usr/atria/bin/cleartool; my @vob_list =

RE: book to learn perl

2006-08-02 Thread Timothy Johnson
For learning the basics I actually recommend Perl From the Ground Up. You can buy a used copy for cheap on Amazon. It doesn't deliver what it says on the cover, but it does a good job of explaining basic concepts for people who don't have any experience in programming. Once you're ready to

Re: file help

2006-08-02 Thread Mumia W.
On 08/02/2006 10:39 AM, Sayed, Irfan (Irfan) wrote: Hi All, Following is the code which i am executing but i am not getting the output of command my $out = system($cmd); into the file. Plz help. Regards Irfan. #/usr/atria/bin/Perl -w use strict; use warnings; my $CT =

Re: match and grab

2006-08-02 Thread John W. Krahn
Rob Dixon wrote: If you miss out the comma with print $1 \n then Perl looks at this as a method call on $1 as an IO::Handle object, or $1-print(\n); No. perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list of strings. Returns

Re: match and grab

2006-08-02 Thread Rob Dixon
John W. Krahn wrote: Rob Dixon wrote: If you miss out the comma with print $1 \n then Perl looks at this as a method call on $1 as an IO::Handle object, or $1-print(\n); No. perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list of

Re: match and grab

2006-08-02 Thread John W. Krahn
Rob Dixon wrote: John W. Krahn wrote: Rob Dixon wrote: If you miss out the comma with print $1 \n then Perl looks at this as a method call on $1 as an IO::Handle object, or $1-print(\n); No. perldoc -f print print FILEHANDLE LIST print LIST print Prints

Re: match and grab

2006-08-02 Thread Rob Dixon
John W. Krahn wrote: perldoc -f print print FILEHANDLE LIST print LIST print Prints a string or a list of strings. Returns true if successful. FILEHANDLE may be a scalar variable name, in which case the variable contains the name of or a