SFTP

2005-05-05 Thread Octavian Rasnita
Hi, Does anyone know a perl module that can be used to get the files from a secure FTP server that listens to port 22? Thanks. Teddy -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: transform array into hash

2005-05-05 Thread Ing. Branislav Gerzo
John Doe [JD], on Friday, May 6, 2005 at 10:10 (+0200) thinks about: JD> Another solution (beside Xavier's one) with no need to know the number of JD> elements: JD> my $i=0; # or even: my $i; my %hash=map {$_ => ++$i} qw /one two three four/; yes, I thought about this one too, but Xaviers one is

Re: transform array into hash

2005-05-05 Thread John Doe
Am Donnerstag, 5. Mai 2005 23.07 schrieb Ing. Branislav Gerzo: > Hi all, > > just easy question, here is too much hours and my brain doesn't work > any more. How to transform array into hash ? > > my @array = 1..4; > > I want to have: > %hash = ( one => 1, two => 2, three => 3, four => 4 ); > > tri

Re: DBI - SELECT by Date

2005-05-05 Thread John Doe
Am Donnerstag, 5. Mai 2005 22.46 schrieb Diogo Nunes de Oliveira: > Hi all, Hi Diogo > I´m having quite a problem here... My script works with postgree. Now i > want to get a result from a date range... But I just can´t get it done... > Explaining... Let´s supose I want to get all registers from

Why don't I need a & to call a function?

2005-05-05 Thread Siegfried Heintze
I've been studying this sample code that someone gave to me in response to one of my earlier queries. Why is it not necessary to put a "&" in front of DBH in the statement DBH->prepare? Thanks, Siegfried use strict; use warnings; use DBI ; use Data::Dumper; our $dbh; sub DBH{ unless ( $db

Re: How to follow a Java script link

2005-05-05 Thread Peter Rabbitson
On Thu, May 05, 2005 at 11:40:52AM -0500, Sergio Ulises Sanchez Buelna wrote: > Hello all > > I am trying to harvest a set of information from a search service that gives > the results of the search by pages. > I am interested in ALL of the results. > I can activate the search and obtain the fir

select the content of matching braces

2005-05-05 Thread baskaran
Dear sirs, How to select the content of the groups suppose the string \newcommand{\sumfun}{\sum_{i=1,2,\ldots}^{n}f(x)} if i use the command s/\\newcommand\{(.*?)\}\{(.*?)\}//g; I get the value 2nd group is "\sum_{i=1,2,\ldots" But my expected output is \sum_{i=1,2,\ldots}^{n}f(x) (i.e. i wan

Re: transform array into hash

2005-05-05 Thread Xavier Noria
On May 5, 2005, at 23:07, Ing. Branislav Gerzo wrote: tried something like this, but it doesnt work: my $hash{qw/one two three four/} = (1..4); You were quite close: my %hash; @hash{qw/one two three four/} = 1..4; The problem was that "my" accepts variables (modulus details), not expressi

RE: transform array into hash

2005-05-05 Thread Moon, John
Subject: transform array into hash Hi all, just easy question, here is too much hours and my brain doesn't work any more. How to transform array into hash ? my @array = 1..4; I want to have: %hash = ( one => 1, two => 2, three => 3, four => 4 ); tried something like this, but it doesnt work: m

transform array into hash

2005-05-05 Thread Ing. Branislav Gerzo
Hi all, just easy question, here is too much hours and my brain doesn't work any more. How to transform array into hash ? my @array = 1..4; I want to have: %hash = ( one => 1, two => 2, three => 3, four => 4 ); tried something like this, but it doesnt work: my $hash{qw/one two three four/} = (1

Re: Favorite Packages for Platform Neutral GUI?

2005-05-05 Thread Daniel Kasak
Siegfried Heintze wrote: Wow! Thanks for the enthusiastic responses! Well I'm a C++ guy so GTK* and WxWindows look good. But is anyone using these on ActiveState Perl? Is there some other perl for windows that I should be using for GUI? Siegfried ActiveState Perl is fine for Gtk2-Perl. At least

DBI - SELECT by Date

2005-05-05 Thread Diogo Nunes de Oliveira
Hi all, I´m having quite a problem here... My script works with postgree. Now i want to get a result from a date range... But I just can´t get it done... Explaining... Let´s supose I want to get all registers from 05/01/2005 to 05/05/2005. How do I do that? I´m trying SELECT * FROM table WHERE dat

RE: How to turn $_ into a hashref?

2005-05-05 Thread KEVIN ZEMBOWER
John, thanks for your thoughts. The foreach loops through a list of authors. The input file has multiple authors separated by a '|' in a single 'author' field. I want to put each author into a table, and link authors to articles with a 'join' table of author ids and article ids. I thought that

Re: How to turn $_ into a hashref?

2005-05-05 Thread KEVIN ZEMBOWER
I think that I found the answer to my first question. I think that this would work: my $authorid = $dbh->selectrow_array("SELECT authorid FROM author WHERE name = ?", undef, ($_)) However, if I use that, or define %db_attrs as Philip suggested at the beginning of my program and use: my $authori

RE: How to turn $_ into a hashref?

2005-05-05 Thread Moon, John
Subject: Re: How to turn $_ into a hashref? Philip, thank you very much. I overlooked the meaning of the second variable to selectrow_array entirely. Two follow up questions: 1. If I don't need or want DBI handle attributes (I'm happy with the defaults, for instance), how can I define a null hash

Re: How to turn $_ into a hashref?

2005-05-05 Thread KEVIN ZEMBOWER
Philip, thank you very much. I overlooked the meaning of the second variable to selectrow_array entirely. Two follow up questions: 1. If I don't need or want DBI handle attributes (I'm happy with the defaults, for instance), how can I define a null hash reference? 2. I chose selectrow_array spec

Re: How to turn $_ into a hashref?

2005-05-05 Thread Philip M. Gollucci
KEVIN ZEMBOWER wrote: I'm using a function from DBI that needs a hash reference according to the documentation, and I don't know how to turn $_ into one. The section of code I have is: if ($record{"Author"}) { my @indfields = split(/\|/, $record{"Author"}); foreach (@indfields) {

How to turn $_ into a hashref?

2005-05-05 Thread KEVIN ZEMBOWER
I'm using a function from DBI that needs a hash reference according to the documentation, and I don't know how to turn $_ into one. The section of code I have is: if ($record{"Author"}) { my @indfields = split(/\|/, $record{"Author"}); foreach (@indfields) { my $authorid =

Re: How to follow a Java script link

2005-05-05 Thread perlocean
- Original Message - From: "Ing. Branislav Gerzo" <[EMAIL PROTECTED]> To: Sent: Thursday, May 05, 2005 12:23 PM Subject: Re: How to follow a Java script link Sergio Ulises Sanchez Buelna [SUS], on Thursday, May 5, 2005 at 11:40 (-0500 (CDT)) wrote the following: SUS> follow_link (this o

Re: How to follow a Java script link

2005-05-05 Thread Ing. Branislav Gerzo
Sergio Ulises Sanchez Buelna [SUS], on Thursday, May 5, 2005 at 11:40 (-0500 (CDT)) wrote the following: SUS> follow_link (this one does not work for the same reason presented before) and SUS> "javascript:mySubmit( 2, 're_search', 25) " SUS> on this reference SUS> previous you have to know, how

How to follow a Java script link

2005-05-05 Thread Sergio Ulises Sanchez Buelna
Hello all I am trying to harvest a set of information from a search service that gives the results of the search by pages. I am interested in ALL of the results. I can activate the search and obtain the first page with results. but when I try to follow the link for the next page I cant do it si

-t STDIN multiple times or doit once and use variable?

2005-05-05 Thread JupiterHost.Net
Hello group, I was wanting opinions on what you think is better and why: Assuming there are several places you need to check and see if the script is being run via terminal or not, would it be better to: if(-t STDIN) { everytime *or* do it once: my $isterminal = -t STDIN; and then do if($istermi

Re: select the content of matching braces

2005-05-05 Thread Peter Scott
On Thu, 05 May 2005 13:54:22 +0530, Baskaran wrote: > How to select the content of the groups suppose the string > > \newcommand{\sumfun}{\sum_{i=1,2,\ldots}^{n}f(x)} > > if i use the command > > s/\\newcommand\{(.*?)\}\{(.*?)\}//g; > > I get the value 2nd group is "\sum_{i=1,2,\ldots" But my e

select the content of matching braces

2005-05-05 Thread baskaran
Dear sirs, How to select the content of the groups suppose the string \newcommand{\sumfun}{\sum_{i=1,2,\ldots}^{n}f(x)} if i use the command s/\\newcommand\{(.*?)\}\{(.*?)\}//g; I get the value 2nd group is "\sum_{i=1,2,\ldots" But my expected output is \sum_{i=1,2,\ldots}^{n}f(x) (i.e. i wa

RE: Favorite Packages for Platform Neutral GUI?

2005-05-05 Thread Siegfried Heintze
Wow! Thanks for the enthusiastic responses! Well I'm a C++ guy so GTK* and WxWindows look good. But is anyone using these on ActiveState Perl? Is there some other perl for windows that I should be using for GUI? Siegfried > >-Original Message->From: Daniel Kasak [mailto:[EMAIL PROTECTE

Re: GUI Packages for ActiveState Perl

2005-05-05 Thread Octavian Rasnita
> > > >What GUI packages would you recommend for an ActiveState Perl? > > Tk is the most supported, and comes standard with ActiveState. > > The only problem with Tk is that it doesn't create graphical interfaces accessible for the screen readers that allow the blind computer users to operate that

Re: Favorite Packages for Platform Neutral GUI?

2005-05-05 Thread Daniel Kasak
Siegfried Heintze wrote: I get the impression that there are several alternatives to use=ing Tk for writing OS neutral GUI programs in Perl. Can anyone point me to a discussion that might help me choose one? I'll give my vote to Gtk2 any day. To start with, Tk looks like barf. It really, really,