[19462] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1657 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Aug 30 11:10:35 2001

Date: Thu, 30 Aug 2001 08:10:15 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <999184215-v10-i1657@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Thu, 30 Aug 2001     Volume: 10 Number: 1657

Today's topics:
        HELP ME: I want to know if with Perl i can use the most (xesquiogx)
        How should perl exit when sent TERM? <bruce.g.mcardle_remove@intel.com>
        I´m from Spain, if you are from Spain could you help me (sin las dos x antes de la @)
    Re: localtime() - returns the wrong year! <tommi.maekitalo@contavia.de>
    Re: Newbie question <bcaligari@fireforged.com>
    Re: Newbie question <godzilla@stomp.stomp.tokyo>
    Re: Pattern matching, grabing everything right of the m (Steve McDonald)
    Re: Perl in Non-IT Work Environments <mjcarman@home.com>
    Re: Perl->M$ SQL <bart.lateur@skynet.be>
        s/\s+$// (Volker Schmidt)
    Re: s/\s+$// <homer@simpsons.com>
    Re: s/\s+$// <godzilla@stomp.stomp.tokyo>
    Re: search.cpan.org <godzilla@stomp.stomp.tokyo>
    Re: search.cpan.org <riechert@pobox.com>
    Re: simple foreach problem (Tad McClellan)
        SQL statement creation module? (Stan Brown)
    Re: SQL statement creation module? <ilya@martynov.org>
        Starting a system application (Windows) <Pcmann1@btinternet.com>
    Re: Starting a system application (Windows) <homer@simpsons.com>
    Re: system call <dbohl@sgi.com>
    Re: system call <Doug.King@abh.siemens.com>
    Re: system call (Anno Siegel)
    Re: system call (Villy Kruse)
        use CGI qw(param) <aort527@hotmail.com>
        Using perl for a server daemon????? (Gary Cub)
        Why do tabs eliminate the rest of the line? (Sara)
    Re: Why do tabs eliminate the rest of the line? <homer@simpsons.com>
    Re: Why do tabs eliminate the rest of the line? <godzilla@stomp.stomp.tokyo>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Thu, 30 Aug 2001 13:56:56 GMT
From: xesquiogx@pobox.com (xesquiogx)
Subject: HELP ME: I want to know if with Perl i can use the most popular scientific functions 
Message-Id: <3b8e44c5.4202260@news.jazzfree.com>

	I´m very interested in know is Perl let me use the scientific
funciton like sin, cos, sqrt, Statisticals functions.

	Thanks

	Best Regards


------------------------------

Date: Thu, 30 Aug 2001 10:10:52 -0400
From: "Bruce McArdle" <bruce.g.mcardle_remove@intel.com>
Subject: How should perl exit when sent TERM?
Message-Id: <9mlhhd$a1m@news.or.intel.com>

I have a strange problem.  This code sometimes will seemingly keep executing
reaper forever if the perl script receives a kill -term:
It's almost always consistent with some people and other people it behaves
correct.  Originaly I had die""; instead of exit(), and I thought that die
was recursively calling the reaper, but exit() does the same thing.

use POSIX ":sys_wait_h";
$SIG{TERM} = sub{reaper()};
$SIG{INT}  = sub{reaper()};
$SIG{QUIT} = sub{reaper()};

fork_process ("sleep 60");

sub fork_process {
    my $exec_line = $_[0];
    # fork the sub process
    if (!defined($kidpid = fork())) {
die "ERROR: cannot fork: $!";
    } elsif ($kidpid == 0) {
 # fork returned 0, so this branch is the child
 $debug && print "starting $exec_line\n";
 exec("$exec_line");
 # if the exec fails, fall through to the next statement
 die "ERROR: can't exec: $!";
    } else {
 # fork returned neither 0 nor undef, so this branch is the parent
 waitpid $kidpid,0;
    $kidpid = 0;
    return $?;
}
} # sub fork_process


sub reaper{
    # if our legitament child really is running
    if ($kidpid) {
# make a list of all children of kidpid and kill them all in one shot code
here...
kill 'TERM', $kidpid;}
    print "received TERM signal\n";
    exit();
} # sub reaper








------------------------------

Date: Thu, 30 Aug 2001 13:56:56 GMT
From: xesquiogx@pobox.com (sin las dos x antes de la @)
Subject: I´m from Spain, if you are from Spain could you help me starting PERL. Thanks
Message-Id: <3b8f45d9.4478563@news.jazzfree.com>




------------------------------

Date: Thu, 30 Aug 2001 14:06:07 GMT
From: Tommi =?ISO-8859-1?Q?M=E4kitalo?= <tommi.maekitalo@contavia.de>
Subject: Re: localtime() - returns the wrong year!
Message-Id: <3B8A58F9.3040608@contavia.de>

Hello Mr. Mann,

localtime is defined that way. See perldoc -f localtime:

   The proper way to get a complete 4-digit year is simply:

     $year += 1900;

   And to get the last two digits of the year (e.g., '01' in 2001) do:

     $year = sprintf("%02d", $year % 100);

Tommi

Peter Mann wrote:

> Dear All,
>     I have a small problem I can't work out! I need to retrieve the current
> date and display it in 'short date' format. This is my code I have to try
> and achieve this! The problem is that is displays
>         '24/07/101'
> The day and month are correct, but 101 for the year isn't! Why wont is give
> me back the correct year?
> 
> sub tasksBehind
> {
>   my (undef, undef, undef, $day, $month, $year) = localtime();
>   print "$day/$month/$year";
> }
> 
> 
> Any suggestions would be much appreciated!
>     Thanks in advance
>             - Pete
> 
> 
> 



------------------------------

Date: Thu, 30 Aug 2001 14:39:58 +0200
From: "B. Caligari" <bcaligari@fireforged.com>
Subject: Re: Newbie question
Message-Id: <9mlbu1026gb@enews1.newsguy.com>


"Ash W" <ash@dailydose.net> wrote in message
news:Okpj7.8212$%P3.64638@news11-gui.server.ntli.net...
> Hi all,
>
> My query was whether there is a way to emulate the Perl interpreter (that
> sits on the server) on a cd rom, so that the site and the scripts would
> function on a standalone cd regardless of whether the viewer has an
internet
> connection or not. The path to the scripts would then be to *something* on
> the CD Rom.


http://www.indigostar.com  have a product called microweb.






------------------------------

Date: Thu, 30 Aug 2001 06:22:59 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: Newbie question
Message-Id: <3B8E3E33.4FE86236@stomp.stomp.tokyo>

Thomas Bätzler wrote:
 
> Ash W  wrote:

(snipped)

> >I've developed a few web sites that are using Perl scripts running in the
> >cgi-bin of the server.

> >My query was whether there is a way to emulate the Perl interpreter (that
> >sits on the server) on a cd rom, so that the site and the scripts would
> >function on a standalone cd regardless of....

> Any particular reason why you can't put an Apache webserver on that
> CD?


Clearly you know very little about Apache. Doing this would
would cause a minimum of three serious errors regarding an
inability of Apache to write an access.log, inability to
write an error log, an inability to write an httpd.pid file
and, an inability to write any other configured logs.

Each time Apache is started from CD disk, Apache would be
unable to write a new httpd.pid file; an impossible task.

This would also prohibit compiling in new Apache modules
without writing a new CD disk and, most annoyingly illogical,
prohibit an ability to configure Apache's httpd configuration
file, access configuration file along with a half-dozen or
so other configuration files including type files such as
Apache's mime.type file.

Apache can only be partially run from a CD disk.


Godzilla!
--
22:11:16 08/28/2001 - RESTRICTED FILE REDIRECT:
   - DNS: localhost - IPA: 127.0.0.1
   - System: Mozilla/GODZILLA! GO GO GODZILLA!
   - Redirect URL: /adl/us.pdf.toolbox/;pos=tower;sz=120x400;tile=3;ord=8282001
   - Referral: http://www.pdfzone.com/products/software/tool_FDFToolkit.html


------------------------------

Date: 30 Aug 2001 07:59:50 -0700
From: steve_mcdonald@choicehotels.com (Steve McDonald)
Subject: Re: Pattern matching, grabing everything right of the match
Message-Id: <acaf067b.0108300659.7ae36613@posting.google.com>

tadmc@augustmail.com (Tad McClellan) wrote in message news:<slrn9oqgqp.4lj.tadmc@tadmc26.august.net>...
> Steve McDonald <steve_mcdonald@choicehotels.com> wrote:
> 
> >Is there a
> >"universal" replacement for "\w+.\w+." that will grab all characters
> 
> 
> Yes:   .*
> 
>  
> It is a little hard to believe that you didn't see that
> yourself when you checked perlre.pod before posting...

Thanks! the .* worked great!


------------------------------

Date: Thu, 30 Aug 2001 08:37:15 -0500
From: Michael Carman <mjcarman@home.com>
Subject: Re: Perl in Non-IT Work Environments
Message-Id: <3B8E418B.4512E4D7@home.com>

James E Keenan wrote:
> 
> I would like to hear from people who are employed in jobs where their
> official responsibilities are *not* primarily IT-related and who use
> Perl on the job.

I'll grant you that a lot of the people on this newsgroup are IT folks,
but it's hardly everyone. It may not even be the majority. I'm a
software engineer. My official duties focus on developing and verifying
software for embedded systems. For me, Perl is a valuable tool in
getting things done. I use it for... well, dozens of things.
 
> I'm not paid as a programmer or technologist.  My employers know
> nothing about my use of Perl.  But being able to extract information
> from databases and reformat it with Perl has been crucial to my
> success. 

My employers *do* know about my use of Perl, because I make a point of
sharing any handy tools I create with my colleagues. This has earned me
a reputation as "the Perl guy" around here, and people will often come
to be with requests for a script for some task that's easy in Perl but
would be slow drudgery to do manually. Now if I can just get more people
to *learn* Perl... :)

-mjc


------------------------------

Date: Thu, 30 Aug 2001 13:50:00 GMT
From: Bart Lateur <bart.lateur@skynet.be>
Subject: Re: Perl->M$ SQL
Message-Id: <sngsotgium16skksiksk3t0152so1u3her@4ax.com>

Nuno wrote:

>Hello, i am working that would connect to a M$ SQL Server and get data.
>
>Can anyone give me some help on this? (interface to use..etc..)

DBI + DBD::ODBC

See <http://dbi.symbolstone.org> and follow some links.

Set up a system DSN using the ODBC control panel, and you can then
connect from within Perl.
<http://tlowery.hypermart.net/perl_dbi_dbd_faq.html#DBDODBCAccess> shows
what your code can look like. That example assumes no user name or
password are necessary, and that the system DSN is called "Northwind".

-- 
	Bart.


------------------------------

Date: Thu, 30 Aug 2001 14:18:26 GMT
From: vollesch@hotmail.com (Volker Schmidt)
Subject: s/\s+$//
Message-Id: <3b8e4ae1.32057295@News.CIS.DFN.DE>


Hi,

We have a perl script here containing the following line:

s/\s+$//

Does anyone of you know what this operation is doing?

Thanks,
Volker


------------------------------

Date: Thu, 30 Aug 2001 15:30:16 +0100
From: "Homer J Simpson" <homer@simpsons.com>
Subject: Re: s/\s+$//
Message-Id: <9mlilr$a8v$1@news.formus.pl>

It removes all white space characters at the end of a string,

Thanks
Homer


"Volker Schmidt" <vollesch@hotmail.com> wrote in message
news:3b8e4ae1.32057295@News.CIS.DFN.DE...
>
> Hi,
>
> We have a perl script here containing the following line:
>
> s/\s+$//
>
> Does anyone of you know what this operation is doing?
>
> Thanks,
> Volker




------------------------------

Date: Thu, 30 Aug 2001 07:38:34 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: s/\s+$//
Message-Id: <3B8E4FEA.7ECF81AD@stomp.stomp.tokyo>

Volker Schmidt wrote:
 
> We have a perl script here containing the following line:

Are you the famous Sybil?

 
> s/\s+$//
 
> Does anyone of you know what this operation is doing?


Yes, this line serves to create a fatal syntax error.


Godzilla!
--
07:10:11 08/30/2001 - RESTRICTED FILE REDIRECT:
   - DNS:  - IPA: 207.196.87.4
   - System: 
   - Redirect URL: /default.ida


------------------------------

Date: Thu, 30 Aug 2001 06:29:08 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: search.cpan.org
Message-Id: <3B8E3FA4.1258F878@stomp.stomp.tokyo>

Rainer Klier wrote:

> since some days I experience performance problems
> accessin search.cpan.org. Am I the only one?
 
I would be more concerned about CPAN's absolutely
miserable search engine.


Godzilla!
--
06:10:06 08/30/2001 - RESTRICTED FILE REDIRECT:
   - DNS: lsiedm-fw.lsiedm.com - IPA: 207.167.12.182
   - System: 
   - Redirect URL: /default.ida


------------------------------

Date: 30 Aug 2001 17:17:36 +0200
From: Andreas Marcel Riechert <riechert@pobox.com>
Subject: Re: search.cpan.org
Message-Id: <m3lmk14lwv.fsf@tairou.japanologie.kultur.uni-tuebingen.de>

Ilya Martynov <ilya@martynov.org> writes:

> >>>>> On Thu, 30 Aug 2001 09:24:41 -0100, Rainer Klier <Rainer.Klier@erl.sbs.de> said:
> 
> RK> Hi,
> RK> since some days I experience performance problems
> RK> accessin search.cpan.org. Am I the only one?
> 
> I see these problems too. Funny, I was intended to post same question
> here.
> 
Suffered the same problem here. Its probably a DNS  problem.
(It seems the server address of search.cpan.org  changed, but 
I am not sure).
BTW, in my case "lists.perl.org" isn't reachable as well since 
a few days.

Andreas 






------------------------------

Date: Thu, 30 Aug 2001 09:58:21 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: simple foreach problem
Message-Id: <slrn9oshjt.79c.tadmc@tadmc26.august.net>

2obvious <vadivasbro@hotmail.com> wrote:
>Thanks, Eric; your fix worked. (Thank you also, Malcolm and Martien.)
>
>So you're saying this is a bug with Windows, and NOT ActiveState Perl?



More specifically, a bug in Windows' command interpreter.


> But isn't ActiveState a port of perl made especially for the Windows
>OS?


Yes, but installing perl is not expected to repair broken OSes :-)


>Do you know if this bug's been reported to ActiveState?


The bug is not in their software, the bug is in Microsoft's software.



[snip Jeopardy quoted text]

-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


------------------------------

Date: 30 Aug 2001 09:07:51 -0400
From: stanb@panix.com (Stan Brown)
Subject: SQL statement creation module?
Message-Id: <9mldr7$64e$1@panix3.panix.com>

Having soent an entire day creating SQL queries by hand in perl, and
curseing the syntax, it ocurs to me that there might be module to do this.

Is there?



------------------------------

Date: 30 Aug 2001 17:18:08 +0400
From: Ilya Martynov <ilya@martynov.org>
Subject: Re: SQL statement creation module?
Message-Id: <87zo8helf3.fsf@abra.ru>

>>>>> On 30 Aug 2001 09:07:51 -0400, stanb@panix.com (Stan Brown) said:

SB> Having soent an entire day creating SQL queries by hand in perl, and
SB> curseing the syntax, it ocurs to me that there might be module to do this.

SB> Is there?

Alzabo, Tangram, DBIx::Recordset and others. CPAN is your friend.

-- 
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
| Ilya Martynov (http://martynov.org/)                                    |
| GnuPG 1024D/323BDEE6 D7F7 561E 4C1D 8A15 8E80  E4AE BE1A 53EB 323B DEE6 |
| AGAVA Software Company (http://www.agava.com/)                          |
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-


------------------------------

Date: Thu, 30 Aug 2001 15:12:13 +0100
From: "Peter Mann" <Pcmann1@btinternet.com>
Subject: Starting a system application (Windows)
Message-Id: <9mlhh9$g2e$1@plutonium.btinternet.com>

Dear All,
    I'm confused as to why the folowing code fragement causes my program to
stop resonding when called! It should just launch the relevant (default)
browser and load the URL. But it just causes the application to freeze!
The weird thing is, upon subsequenty using task manager to termine the
application, the browser then loads with the specified URL! I realise this
code is specific to windows platforms! (I use Win2 000)
Does anyone know why it wont do the simple job its supposed to?

sub previewReport
{
  my $url='http://www.perl.com';
  system('start',$url);
}


Any comments would be great appreciated!
    Thanks in advance
          - Pete




------------------------------

Date: Thu, 30 Aug 2001 15:28:16 +0100
From: "Homer J Simpson" <homer@simpsons.com>
Subject: Re: Starting a system application (Windows)
Message-Id: <9mlii4$9u7$1@news.formus.pl>

Seems as suspect way of doing it if you ask me,

$url = http://www.perl.com;
`start $url`;

 ...works much better...

Thanks
Homer


"Peter Mann" <Pcmann1@btinternet.com> wrote in message
news:9mlhh9$g2e$1@plutonium.btinternet.com...
> Dear All,
>     I'm confused as to why the folowing code fragement causes my program
to
> stop resonding when called! It should just launch the relevant (default)
> browser and load the URL. But it just causes the application to freeze!
> The weird thing is, upon subsequenty using task manager to termine the
> application, the browser then loads with the specified URL! I realise this
> code is specific to windows platforms! (I use Win2 000)
> Does anyone know why it wont do the simple job its supposed to?
>
> sub previewReport
> {
>   my $url='http://www.perl.com';
>   system('start',$url);
> }
>
>
> Any comments would be great appreciated!
>     Thanks in advance
>           - Pete
>
>




------------------------------

Date: Thu, 30 Aug 2001 08:16:41 -0500
From: Dale Bohl <dbohl@sgi.com>
Subject: Re: system call
Message-Id: <3B8E3CB9.8C4416E8@sgi.com>

Ren Maddox wrote:
> 
> On Wed, 29 Aug 2001, dbohl@sgi.com wrote:
> 
> >    I'm developing a perl program that does a rsh to a list
> > of Unix clients and returns the size of /etc/passwd.
> >
> > How do I get the following to work with a system call
> > from Perl?
> >
> > $command = "ls -la /etc/passwd | awk '{print $5}'";
> >
> > After this I do a system ("rsh $host $command");
> >
> > I can't figure out how to get the | awk '{print $5}'
> > part working.
> 
> The $5 is probably causing you pain.  That, combined with the single
> quotes.  Try:
> 
> $command = q(ls -la /etc/passwd | awk '{print $5}');
> system "rsh $host $command";
> 
> --
> Ren Maddox
> ren@tivoli.com

Ren,

   That's what I was looking for.  I'll need to watch my
quotes more closely in the future.


-- 

Thanks,
Dale

Dale Bohl
SGI Information Services
dbohl@sgi.com
(715)-726-8406
http://wwwcf.americas.sgi.com/~dbohl/


------------------------------

Date: Thu, 30 Aug 2001 09:18:13 -0400
From: Doug King <Doug.King@abh.siemens.com>
Subject: Re: system call
Message-Id: <3B8E3D14.A78792E0@abh.siemens.com>



Anno Siegel wrote:

> According to Doug King  <Doug.King@abh.siemens.com>:
> >
> >
> > Tad McClellan wrote:
> >
> > > Dale Bohl <dbohl@sgi.com> wrote:
> > > >Doug King wrote:
> > > >>
> > > >> Don't do the | awk '{print $5}' in your rsh command, and just parse the
> > > >> output of the ls command in perl.
> > >
> > > Don't do the "ls -l" in your rsh command either:
> > >
> > >    $size = -s '/etc/passwd';
> >
> > But, that only gives you the size of the /etc/passwd file on the machine the
> > perl script is running on.  He needs the size of the file on the remote
> > machines.  Is there a perl-only way to do this? That doesn't rely on perl
> > being on the remote machine? ...
>
> How do you expect that to work when the foreign system runs under some
> Martian OS?  It may not even have files.
>
> Anno

I think I cut too much of the original post...

Dale (the original poster's) assumption: the remote machine runs *NIX, and he
wants to know the size of the /etc/passwd file.  For a Martian OS without files,
the concept of file size could not even exist, so his problem could not exist
either. :-)





------------------------------

Date: 30 Aug 2001 14:00:21 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: system call
Message-Id: <9mlgtl$ifo$2@mamenchi.zrz.TU-Berlin.DE>

According to Doug King  <Doug.King@abh.siemens.com>:
> 
> 
> Anno Siegel wrote:
> 
> > According to Doug King  <Doug.King@abh.siemens.com>:
> > >
> > >
> > > Tad McClellan wrote:
> > >
> > > > Dale Bohl <dbohl@sgi.com> wrote:
> > > > >Doug King wrote:
> > > > >>
> > > > >> Don't do the | awk '{print $5}' in your rsh command, and just parse the
> > > > >> output of the ls command in perl.
> > > >
> > > > Don't do the "ls -l" in your rsh command either:
> > > >
> > > >    $size = -s '/etc/passwd';
> > >
> > > But, that only gives you the size of the /etc/passwd file on the machine the
> > > perl script is running on.  He needs the size of the file on the remote
> > > machines.  Is there a perl-only way to do this? That doesn't rely on perl
> > > being on the remote machine? ...
> >
> > How do you expect that to work when the foreign system runs under some
> > Martian OS?  It may not even have files.
> >
> > Anno
> 
> I think I cut too much of the original post...
> 
> Dale (the original poster's) assumption: the remote machine runs *NIX, and he
> wants to know the size of the /etc/passwd file.  For a Martian OS without files,
> the concept of file size could not even exist, so his problem could not exist
> either. :-)

The point was rather that you need collaboration from the foreign system,
so a Perl-only solution doesn't exist.  Even if it's Unix (designed by
Martians, or a committee) some assumptions about it may fail.

Anno


------------------------------

Date: 30 Aug 2001 14:05:12 GMT
From: vek@pharmnl.ohout.pharmapartners.nl (Villy Kruse)
Subject: Re: system call
Message-Id: <slrn9osi0o.vh8.vek@pharmnl.ohout.pharmapartners.nl>

On 30 Aug 2001 10:35:19 GMT,
    Anno Siegel <anno4000@lublin.zrz.tu-berlin.de> wrote:


>
>How do you expect that to work when the foreign system runs under some
>Martian OS?  It may not even have files.
>


You do need to assume that the OP knows the remote system is a unix system
before even considering runing remote shell on that system.


Villy


------------------------------

Date: Thu, 30 Aug 2001 09:09:58 -0500
From: alex <aort527@hotmail.com>
Subject: use CGI qw(param)
Message-Id: <3B8E4936.38B7AC76@hotmail.com>

newbie here.  trying to use "use CGI qw(param)" in
my perl script but it appears that it can't find
the CGI.pm MODULE.  my script resides in
\inetpub\wwwroot\cgi-bin directory and
I found CGI.pm in      \PERL\LIB.

how do I tell my script to go to this
\PERL\LIB directory to find the CGI.PM
module.  do i code something like:
use C:\PERL\LIB\CGI qw(param)

this doesn't work.  help....



------------------------------

Date: 30 Aug 2001 07:29:06 -0700
From: gary@irl.com (Gary Cub)
Subject: Using perl for a server daemon?????
Message-Id: <d3786cd7.0108300629.7f4c51cf@posting.google.com>

Hi,

   I have been asked to build a server daemon to run on a Linux
platform and was thinking about doing it in PERL.  Can anyone tell me
of any security problems their would be in using PERL over C, as I
prefer PERL.
   Also, if there is no reasons not to use PERL why then are more
server daemons written in PERL??

Thanks for your help
Gary


------------------------------

Date: 30 Aug 2001 06:54:07 -0700
From: genericax@hotmail.com (Sara)
Subject: Why do tabs eliminate the rest of the line?
Message-Id: <776e0325.0108300554.2360bb85@posting.google.com>

I have a statement like:

 my $beginc="
*
* JOB#$newjob   $today
* $newjob       ITEM: $l{LA}    PRICE: $l USD
";

where TABS are inserted before $today and ITEM. When this prints I end
up with:

*
* JOB#30339
* B3459

So it appears that everything after the inserted TAB characters is
erased. Why? By the way this WAS working on another system, and when
we moved to this system (both v 5.6) it stopped working.

Thank-You for your insights.


------------------------------

Date: Thu, 30 Aug 2001 15:33:32 +0100
From: "Homer J Simpson" <homer@simpsons.com>
Subject: Re: Why do tabs eliminate the rest of the line?
Message-Id: <9mlis2$aps$1@news.formus.pl>

It looks more like the values $newjob and $today are empty,

Anyway you'll have to provide more information... like some code...


"Sara" <genericax@hotmail.com> wrote in message
news:776e0325.0108300554.2360bb85@posting.google.com...
> I have a statement like:
>
>  my $beginc="
> *
> * JOB#$newjob   $today
> * $newjob       ITEM: $l{LA}    PRICE: $l USD
> ";
>
> where TABS are inserted before $today and ITEM. When this prints I end
> up with:
>
> *
> * JOB#30339
> * B3459
>
> So it appears that everything after the inserted TAB characters is
> erased. Why? By the way this WAS working on another system, and when
> we moved to this system (both v 5.6) it stopped working.
>
> Thank-You for your insights.




------------------------------

Date: Thu, 30 Aug 2001 07:51:52 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: Why do tabs eliminate the rest of the line?
Message-Id: <3B8E5308.AA5BC88F@stomp.stomp.tokyo>

Homer J Simpson wrote:

> Sara wrote:

(snipped)

> >  my $beginc="
> > *
> > * JOB#$newjob   $today
> > * $newjob       ITEM: $l{LA}    PRICE: $l USD
> > ";

> > where TABS are inserted before $today and ITEM. When this prints I end
> > up with:

> > *
> > * JOB#30339
> > * B3459

> > So it appears that everything after the inserted TAB characters is
> > erased. Why? By the way this WAS working on another system, and when
> > we moved to this system (both v 5.6) it stopped working.

 
> It looks more like the values $newjob and $today are empty,
 
With all variables and the hash reference not initialized / undefined,
this would still print:

*
* JOB#
*       ITEM:   PRICE:  USD


Godzilla!


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V10 Issue 1657
***************************************


home help back first fref pref prev next nref lref last post