On 22/08/12 03:49, Uri Guttman wrote:
On 08/21/2012 08:29 PM, Eduardo wrote:
how would you do with Sort::Maker?
i don't have time to show an example now but it is much cleaner
looking. all you need to do is code up how you extract each key from
the data set and how it gets sorted (number vs
$naa == $nba;
return $nab = $nbb;
}
with this loop:
foreach ( sort sorted keys $hash )
{
print $_\n;
}
Eduardo.
--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/
On 22/08/12 00:35, Uri Guttman wrote:
On 08/21/2012 05:33 PM, Eduardo wrote:
On 21/08/12 22:05, Chris Stinemetz wrote:
Hello List,
I am trying to sort a hash of arrays ( example below: )
I would the sort to sort in ascending order the first index of the
array
then the second index
scripts in 5:10
2010/3/29 Shlomi Fish shlo...@iglu.org.il
On Monday 29 Mar 2010 17:47:30 Eduardo Terzella wrote:
Look with using PAR.
pp -o testeC teste.pl
teste.pl
#!/usr/bin/perl
print Hello World\n;
Size file:
teste.pl = 4.0 k
testeC = 3.6 M
it.
2010/3/29 Shlomi Fish shlo...@iglu.org.il
Replying to the list, next time - hit reply to all.
On Monday 29 Mar 2010 17:29:15 Eduardo Terzella wrote:
I know it's possible to open my obfuscate your source code, but I want
something just
that impede it. I used the perlcc, so that the version
Unsubscrime from the list
Thank U
--
If I have seen further it is by standing on the shoulders of the giants
Isaac Newton
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/ http://learn.perl.org/first-response
Hello
Does anybody has already programmed the way of using the COPY FROM
function from postgres, I try producing the following code:
my ($dbh, $sth10);
$dbh = DBI-connect(dbi:Pg:dbname=$database, $username, $password)
or die Error: $DBI::errstr \n;
$sth10 = $dbh-prepare (COPY
Where did you install perl?
Does your environment variables are pointing to the new perl version?.
I had the same error and I fixed changing the usual path /usr/bin/perl
to the new one /usr/local/bin/perl, just use the ln command
As long as I remember the newer versions of perl are installed
Hello perl addicts!
Is there a possible way of executing a Perl Script so that it uses not
only one Solaris Processor?
What I want is that my script use more than one processor, because they
took much time to execute.
What I do with my scripts are parsing log files (each one about 800 000
I know that programming is not one of my best skills, but this code
works for me, your help is very appreciate
open(INPUT, $file) or die Can't read from file: $! $file;
# Where we move the pointer to line number 10
$. = 0;
do
{
$_ = INPUT
}
until $. == 10;
Hello Perl Programmers
I have a question regarding openning a file
How can I start reading a file from n line?
For example
I open a File like this way
open(INPUT, $file)
while (INPUT)
{
do something with $_;
}
But It starts to read from line #1, what I want is that start reading
exactly
]
To
Perl Beginners
beginners@perl.org
02/14/2005 04:13
cc
PM
Subject
Re: Start reading from a specific
line
Eduardo Vázquez Rodríguez wrote:
Hello Perl
Did you have already check the compile process of the Perl Module that
provides access to Postgres?
If you have do it. Then my code might help you
use DBI;
use diagnostics;
use strict;
my $database=Database;
my $username=postgres;
my $password=123;
my ($mbd, $sth1);
$mbd =
Hello
Im writing perl scripts that use threads.
Mi goal is that each thread could process an element of an array that
has 10 elements, so thread0 process array[0], thread1 process array[1]
and so on until thread9 process array[9]
Those 10 lines come from a file that Perl reads in chunks of ten
Hello everybody!
My intention is to have thread support in Perl, reding through CPAN I
must have a Perl version compiled with support to threads. I made a
script and I have the following output
This Perl hasn't been configured and built properly for the threads
module to work. (The
Hello everyone
I have a question, how do I open a file in a specific line number, for
example I want to open a text file exactly on line number 5,
Thanks in advanced
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
Thanks Chris I try this and works
$. = 0;
do
{
$_ = INPUT
}
until $. == 5;
WHILE INPUT
{
Do_whatever_you_like_begining_after_line_5(); :-)
}
Chris Devers wrote:
On Wed, 29 Sep 2004, Eduardo Vázquez Rodríguez wrote:
I have a question
Hello everybody out there using postgres and perl
I am writing Perl scripts with the purpouse of parsing text and
inserting the text parsed into a database, which I choose Postgresql.
My scripts are many, exactly 7, if I ran each one of them sequencially,
my processing speed is about 200 lines
Hello everyone out there using Perl.
Im doing perl scripts that parses log files of networking devices.
In this forum thanks to everyone suggest me to take several lines at time. I
can do that already, but I have another problem.
If I read 5 lines at time I have to process each once at time,
Using regular expressions I match a criteria in a text string, such as:
@duration = $string =~ /\sduration=(.*?)\s/;
The first element in duration contains 1.23, in a string format
When I try to insert $duration[0], into a field of integer type in a database,
I get the Following error:
Error
September 2004 01:49 pm, Jeff 'japhy' Pinyan wrote:
On Sep 9, Eduardo Vazquez Rodriguez said:
@duration = $string =~ /\sduration=(.*?)\s/;
The first element in duration contains 1.23, in a string format
When I try to insert $duration[0], into a field of integer type in a
database, I get
lines at the same time? can
anyone suggest any better strategy?
--
Eduardo Vázquez Rodríguez [EMAIL PROTECTED]
Consultoría Implantación
Tel. 5322 5200
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/ http://learn.perl.org/first
I think he is from Croatia. moreover in the last part of this message I
think what he is pretending is to accomplish a better way of inserting
into the database.
I think that one of his goals is to avoid the use of the variable names
when inserting I believe that he pretends to catch the
Hello everybody out there using Perl- Im doing a perl scripts, which
objective is to parse text.
I am looking for a way of creating a perl binary, my intention is that
no one can read the scripts in a human readable way.
Thanks in advance
--
Eduardo Vázquez Rodríguez [EMAIL PROTECTED
Sorry, won't happen again.
On Thursday, January 30, 2003, at 10:09 AM, [EMAIL PROTECTED] wrote:
Please be sure to always group reply.
On Thu, 30 Jan 2003 09:12:15 -0600, Eduardo Cancino
[EMAIL PROTECTED] wrote:
As I recall installing Perl
Hi :
My box - eMac, MacOSX Jaguar 10.2.1, DevTools installed
After installing perl 5.8.0, I ran a perl script, and perl send this
message:
error
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LC_ALL = (unset),
LANG = en_US
are
Hi Enlightened Ones...
I need to build a website that has a classification like this
h - human
n - natural resources
i - enviroment impact
and then subclasses
ie.
h6 - health
and then the object
h6.1 - Aids
For this I have every text in .rtf and I have a excel datasheet for the
video
Hi.
I'm parsing a text file with this estrcuture line:
'here is a quote'. Autor (birth year - death year); occupation nationality.
==
I need to separate from the beggining to the first dot, ignoring the dots in
side the two ''.
but i have tried to escape the ' (\'), but no use, what i'm
Hello!
I have a lot of trouble understanding regexes, i just don't get how to parse
a file with:
Hablar es el arte de sofocar e interrumpir el pensamiento. Thomas Carlyle
(1795-1881); historiador y ensayista escocés.
Se aprende más por lo que la gente habla entre sí o por lo que se
HI.
I'm having this problem I have a memo field that i use for the main text and
when i access it my script just prints a blank page, but when the field is
reduced my scripts prints exactly as i want to:
You know why??
SOME CODE
#!c:/perl/bin/perl.exe
# cargar modulos
use DBI;
use CGI
I have this problem now, maybe is not about perl but here I go:
I connected an Access Datasource to a cgi, (made in Perl ;), but while in
the command line runs perfectly, as a CGI, on my host, it outputs:
Software error:
No pude conectarme : (DBD: db_login/SQLConnect err=-1)
I know that maybe
But how do I know who the correct user is???
I have tried todos (all) the admin
but it doesnot work!
-Mensaje original-
De: David Kirol [mailto:[EMAIL PROTECTED]]
Enviado el: Martes, 23 de Abril de 2002 02:45 p.m.
Para: Eduardo Cancino
Asunto: RE: [OT] DBI-ODBC WIN2K
Eduardo
:[EMAIL PROTECTED]]
Enviado el: Martes, 23 de Abril de 2002 02:45 p.m.
Para: Eduardo Cancino
Asunto: RE: [OT] DBI-ODBC WIN2K
Eduardo,
Review your connect string. Make sure a user is specified. If not the CGI
script's 'user' (usually nobody) will be passed and the db will reject it.
HTH
Hi everybody, i'm new to perl and i want to connect to an access database.
I'm using DBI::ODBC but returns that it can connect to my database:
Can't connect to database: [Microsoft][ODBC Driver Manager] Data source name
not found and no default driver specified (SQL-IM002)(DBD:
Hi everybody!
The next script runs looks pefectly in IE but in Netscape it shows the
source of the html...
#!c:/perl/bin/perl.exe
# recibe la forma.
read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'});
@pairs = split(//, $buffer);
# inicia variables.
$to = info\@domain.mx;
$from = info\@domain.mx;
???
Thanks everybody...
Lalo.
- Original Message -
From: Jeff 'japhy' Pinyan [EMAIL PROTECTED]
To: Eduardo Cancino [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Thursday, January 24, 2002 10:39 PM
Subject: Re: What's wrong with this?
On Jan 24, Eduardo Cancino said:
The next script
36 matches
Mail list logo