Wiggins d'Anconia <[EMAIL PROTECTED]> wrote:
> Though it seems a bit odd that you want to recursively read a
> filehandle.
It certainly would be a cool way to handle include
directives when parsing config files, i.e.
my $conf = "/etc/apache/httpd.conf"
open( my $fh, $conf ) or die "Can't open '
Oops ,
Mine was a wild guess and I am sorry for that. The below test was
successful in setting environment variable ...
clip
#!/usr/bin/perl
use Env;
print "Before -->";
print %ENV;
print "\n";
$ENV{TEMP}="xxx";
print "After --> \n";
print %ENV;
print "\n";
system("ec
Japerlh wrote:
> How can we read files recursively?
>
> Seems like filehandler is a global variable, no matter where it was defined.
> and put a openfile in a recursion function doesn't work.
>
> Anyone can give me any hints?
perldoc -q filehandle
John
--
To unsubscribe, e-mail: [EMAIL PROTE
"Because it's up-side down.
Why is that?
It makes replies harder to read.
Why not?
Please don't top-post." - Sherm Pendley, Mac OS X list
[EMAIL PROTECTED] wrote:
> Hi ,
> Try below.
> If you are using csh for executing perl script --> system("setenv
> TEMPHOME /tmp ");
> If your using bas
Hi ,
Try below.
If you are using csh for executing perl script --> system("setenv
TEMPHOME /tmp ");
If your using bash for executing perl script -> $TEMPHOME =
"/tmp";
system("export $TEMPHOME");
Arjun
Deserve before you desire
-Original Message-
From: Nishi Pra
Japerlh wrote:
> How can we read files recursively?
>
> Seems like filehandler is a global variable, no matter where it was defined.
> and put a openfile in a recursion function doesn't work.
>
> Anyone can give me any hints?
> Thanks a lot.
>
>
In newer perl's you can store a filehandle direc
How can we read files recursively?
Seems like filehandler is a global variable, no matter where it was defined.
and put a openfile in a recursion function doesn't work.
Anyone can give me any hints?
Thanks a lot.
--
Besh wishes,
Japerlh
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additi
Lawrence Statton wrote:
>>On Mon, 2005-07-18 at 11:53, Wiggins d'Anconia wrote:
>>
>>>Charles Farinella wrote:
>>>
I'm sure this is very simple and I am overlooking something. I want to
read a list of bad email addresses from a file and remove them from my
database.
If I pri
> -Original Message-
> From: Ron Smith [mailto:[EMAIL PROTECTED]
> Sent: Monday, July 18, 2005 12:50 PM
> To: Perl
> Subject: Error on: my $sth->execute;
>
>
> Hi all,
>
> I'm getting an error when trying to do an INSERT statement to
> a MySQL database. There's something I'm not under
Mathias Pasquay wrote:
> Dear list,
Hello,
> i'am just wondering about the behaviour of shift and the defaultvariable @_ .
>
> I use the following code::
>
> while () { # each line of RULEFILE is stored in
> $_
> chomp;# delete \n from $_
>
Hi:
I need to run a script noted by $cmd1 from within perl but before that
i need to set the environment variable. how can i do it?
I tried
my $TEMPHOME = "/tmp";
system($cmd1);
But the script still complains the $TEMPHOME is not set.
Thanks.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For addi
One other thing that's bugging me about this is how to provide the
config data to the scripts at runtime in a web environment.
If this were a one-time script it would be simple to hard-code them in,
but we expect to be able to re-use the package for multiple client
environments.
The constrai
I ttied it inside the perl script, but does not seem to work.
I did a echo for $TEMPHOME but it was not set.
On 7/18/05, John W. Krahn <[EMAIL PROTECTED]> wrote:
> Nishi Prafull wrote:
> > Hi:
>
> Hello,
>
> > I need to run a script noted by $cmd1 from within perl but before that
> > i need to
--- Lawrence Statton <[EMAIL PROTECTED]> wrote:
> > --0-551411304-1121705388=:507
> > Content-Type: text/plain; charset=iso-8859-1
> > Content-Transfer-Encoding: 8bit
> >
> > Hi all,
> >
> > I'm getting an error when trying to do an INSERT
> statement to a MySQL databas
> > e. There's something
Perl'ers
I my code I wrote a routine that executes return code signals. My point
being is if after any particular line of code make a call to check its
success or failure.
My question is if after any code system call or non system call failure
according to
$? == -1
? & 127 or
$?
Nishi Prafull wrote:
On 7/18/05, John W. Krahn <[EMAIL PROTECTED]> wrote:
Nishi Prafull wrote:
Hi:
Hello,
I need to run a script noted by $cmd1 from within perl but before that
i need to set the environment variable. how can i do it?
I tried
my $TEMPHOME = "/tmp";
system($cmd1);
But th
Nishi Prafull wrote:
> Hi:
Hello,
> I need to run a script noted by $cmd1 from within perl but before that
> i need to set the environment variable. how can i do it?
> I tried
> my $TEMPHOME = "/tmp";
> system($cmd1);
>
> But the script still complains the $TEMPHOME is not set.
> Thanks.
You pr
Jeff 'japhy' Pinyan wrote:
On Jul 13, Scott R. Godin said:
http://www.webdragon.net/miscel/DB.pm
I'll check it out.
All Subscriber::DB objects would share the DBI object -- there's no
need for a billion database handles.
ok, so possibly one should do it differently than I have, in my exa
On 7/18/05, Adriano Ferreira <[EMAIL PROTECTED]> wrote:
> Beware of the difference of double and single quotes in Perl. Double
> quotes interpolate:
Oops. That's my mistake. Your single quotes are within double quotes.
Let's try again. I would say that something is wrong here:
my $sth = $dbh
On 7/18/05, Ron Smith <[EMAIL PROTECTED]> wrote:
> my $sql = "INSERT INTO products VALUES ('$sku', '$partNum', '$name',
> '$descr', '$stockNum', '$qty', '$img', 'vendNum', '$price')";
Beware of the difference of double and single quotes in Perl. Double
quotes interpolate:
$a = 3;
print "a: $a\n"
Roberts Mr Richard L wrote:
> Hi,
> Does anyone know how/where I can resolve scp pdf files (user selected) and
> display in a web page?
> thanks
> -r
>
I suspect the reason this post hasn't gotten more response is because it
is incredibly unclear. What do you mean by "how/where" or "resolve" or
"
Hi all,
I'm getting an error when trying to do an INSERT statement to a MySQL database.
There's something I'm not understanding here. Can anyone point me in the right
direction? I also tried a "do" method, but got the same error. I know the
"param" function is loading the values from the form,
Charles Farinella wrote:
> On Mon, 2005-07-18 at 11:53, Wiggins d'Anconia wrote:
>
>>Charles Farinella wrote:
>>
>>>I'm sure this is very simple and I am overlooking something. I want to
>>>read a list of bad email addresses from a file and remove them from my
>>>database.
>>>
>>>If I print $_,
On Mon, 2005-07-18 at 11:53, Wiggins d'Anconia wrote:
> Charles Farinella wrote:
> > I'm sure this is very simple and I am overlooking something. I want to
> > read a list of bad email addresses from a file and remove them from my
> > database.
> >
> > If I print $_, the email addresses are cor
Oops - mean't to group reply
On 7/18/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> H. Maybe techno enough to know how to download stuff his
> mummy and daddy wouldn't approve of??
>
> On 7/17/05, robert johnson <[EMAIL PROTECTED]> wrote:
> >
> > so, am i to read his email as "kisses
[EMAIL PROTECTED] wrote:
> By the way, since you mentioned chomp - what is the difference
> between chomp and chop? I think they are both for removing some type
> of un-needed whitespace - does one do space, and the other newline or
> something?
>
>> also chomp() the $guess variable to remove
Charles Farinella wrote:
> I'm sure this is very simple and I am overlooking something. I want to
> read a list of bad email addresses from a file and remove them from my
> database.
>
> If I print $_, the email addresses are correct, if I try to remove them
> from the db I get errors on just t
[EMAIL PROTECTED] wrote:
> By the way, since you mentioned chomp - what is the difference between
> chomp and chop? I think they are both for removing some type of
> un-needed whitespace - does one do space, and the other newline or
> something?
>
>
>>also chomp() the $guess variable to remove t
By the way, since you mentioned chomp - what is the difference between
chomp and chop? I think they are both for removing some type of
un-needed whitespace - does one do space, and the other newline or
something?
> also chomp() the $guess variable to remove the unneeded newline.
--
Dave
All u
Subject: escaping @
I'm sure this is very simple and I am overlooking something. I want to
read a list of bad email addresses from a file and remove them from my
database.
If I print $_, the email addresses are correct, if I try to remove them
from the db I get errors on just the characters be
On 7/16/05, Chris Devers <[EMAIL PROTECTED]> wrote:
> On Thu, 14 Jul 2005, Beast wrote:
>
> > I have prototype that should parse big log files (680MB) converted
> > into nice GUI apps. It's not nice if the machine totaly freeze during
> > testing. (linux 512MB/2GB swap).
>
> Are you trying to rea
I'm sure this is very simple and I am overlooking something. I want to
read a list of bad email addresses from a file and remove them from my
database.
If I print $_, the email addresses are correct, if I try to remove them
from the db I get errors on just the characters before the @.
Here is
On Jul 18, 2005, at 10:57, Mathias Pasquay wrote:
Now i change the line "my $test = shift @_" into "my $test =
shift". This should work because shift should use @_ by default.
But in this case $test is empty an the second print command prints
still the whole @_.
Have a look at perldoc -f sh
Dear list,
i'am just wondering about the behaviour of shift and the defaultvariable @_ .
I use the following code::
while () { # each line of RULEFILE is stored in $_
chomp;# delete \n from $_
split /;/; #
34 matches
Mail list logo