[23011] in Perl-Users-Digest
Perl-Users Digest, Issue: 5231 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Jul 17 06:05:49 2003
Date: Thu, 17 Jul 2003 03:05:09 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Thu, 17 Jul 2003 Volume: 10 Number: 5231
Today's topics:
ASP --> PERL SCRIPT <brianberneker@hotmail.com>
Re: ASP --> PERL SCRIPT <nospam@nospam.com>
Configure win98 to work with a cgi written in perl (iris)
Re: Help needed badly! VIZBOOK date file path? <mgjv@tradingpost.com.au>
Re: Help understanding MAP <Jodyman@hotmail.com>
Re: Help understanding MAP <parv_fm@emailgroupsWhereElse.net>
Re: macros in perl <REMOVEsdnCAPS@comcast.net>
Re: Newbie OO question <dodgynewsgroups@ewildgoose.demon.co.uk>
Re: Opening a socket connection on a serial port (John Ramsden)
Re: Opening a socket connection on a serial port (John Ramsden)
Re: Problem executing a BAT file (or EXE file) using Pe (Bryan Castillo)
Removing Perl comments and strings using regexps <SineSwiper@ResonatorSoft.org>
Re: Removing Perl comments and strings using regexps (Jay Tilton)
Re: Removing Perl comments and strings using regexps <REMOVEsdnCAPS@comcast.net>
Test for file existence <brianberneker@hotmail.com>
Re: Test for file existence <tassilo.parseval@rwth-aachen.de>
Re: Test for file existence <nospam@nospam.com>
Re: Use module (maybe) w/o dying <REMOVEsdnCAPS@comcast.net>
Re: Using Perl / MYSQL for a large database application <chad@vellum.demon.co.uk>
Re: Using Perl / MYSQL for a large database application <nospam@nospam.com>
Re: Using Perl / MYSQL for a large database application <mgjv@tradingpost.com.au>
Re: Where are the perl folks? <tassilo.parseval@rwth-aachen.de>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 17 Jul 2003 02:00:35 -0400
From: "Brian Berneker" <brianberneker@hotmail.com>
Subject: ASP --> PERL SCRIPT
Message-Id: <bf5e27$v79$1@news1.mountaincable.net>
try using $ENV{THIS_SCRIPT}
------------------------------
Date: Thu, 17 Jul 2003 07:41:50 GMT
From: "Gregory Toomey" <nospam@nospam.com>
Subject: Re: ASP --> PERL SCRIPT
Message-Id: <2rsRa.143$OM3.71@news-server.bigpond.net.au>
"Brian Berneker" <brianberneker@hotmail.com> wrote in message
news:bf5e27$v79$1@news1.mountaincable.net...
> try using $ENV{THIS_SCRIPT}
Yes, you've worked out line 1 of your ASP-> Perl translator. Only 9999 more
to go.
gtoomey
------------------------------
Date: 17 Jul 2003 02:03:07 -0700
From: sassonir@bgumail.bgu.ac.il (iris)
Subject: Configure win98 to work with a cgi written in perl
Message-Id: <18fcd0e0.0307170103.6a5147b3@posting.google.com>
Hi
I have downloaded perl to my computer and would like to work on a cgi
file.
However, i can not get the system to return the html file.
This thing works on unix so i know i have problems in the win98
configuration.
Also, when i run it on windows a dos window is opened, but it closes
so quickly that i can not read the messages there.
How do i configure win 98 to work with cgi?
Thanks,
Iris.
------------------------------
Date: 17 Jul 2003 02:14:50 GMT
From: Martien Verbruggen <mgjv@tradingpost.com.au>
Subject: Re: Help needed badly! VIZBOOK date file path?
Message-Id: <slrnbhc1ks.1rf.mgjv@verbruggen.comdyn.com.au>
On 16 Jul 2003 06:07:35 -0700,
Andy <warmesfeuer@web.de> wrote:
> Help needed!
>
> I tried to install Vizbook on my hoempage today, created all dirs
[snip request for help with installation of software]
have you tried contacting the author of the software? None of this has
anything to do with Perl, and everything with the software you're
trying to install.
Martien
--
|
Martien Verbruggen |
Trading Post Australia | Hi, Dave here, what's the root password?
|
------------------------------
Date: Thu, 17 Jul 2003 04:01:37 GMT
From: "Jodyman" <Jodyman@hotmail.com>
Subject: Re: Help understanding MAP
Message-Id: <BcpRa.105444$Io.9019371@newsread2.prod.itd.earthlink.net>
"Perusion hostmaster" <nanae@perusion.com> wrote in message :
:: Jodyman
:: my $n = 0;
:: my %b = map { $_ => $n++ } @na;
>Perusion hostmaster
> Just a little list context problem. Without surrounding parens, the
> second value is output as the result of the map (remember => is nothing
> but a comma in practice).
>
> my @na = ( 48 .. 57, 65 .. 90 );
> my $n = 0;
> my %b = map { ($_ => $n++) } @na;
>
> use Data::Dumper;
> $Data::Dumper::Terse = 1;
>
> print Dumper(\%b);
After using data dumper, I indeed saw I had data in my hash. It turns
out what I was really looking for was:
$n = 0;
my %br = map { ($n++ => $_) } @na;
What I saw with data dumper was:
'0' => 48,
'1' => 49,
Thus by using print chr($br{10}) I would get A.
Thanks for your help guys!
Jodyman
------------------------------
Date: Thu, 17 Jul 2003 09:17:06 GMT
From: parv <parv_fm@emailgroupsWhereElse.net>
Subject: Re: Help understanding MAP
Message-Id: <slrnbhcqhn.dul.parv_fm@localhost.holy.cow>
in message <4dafc536.0307160349.6045a71d@posting.google.com>,
wrote nobull@mail.com ...
> "Christian Winter" <thepoet@nexgo.de> wrote in message news:<3f14f4b1$0$6766$9b4e6d93@newsread2.arcor-online.net>...
>
>> If i got it right, you then simply want to construct
>> a reverse hash in %b36.
> ^^^^^^^
>
>> my %b36 = map { $b{$_} => $_ } keys %b;
>
> Why use map at all? Why not simply reverse it?
>
> my %b36 = reverse %b;
I personally prefer the mapping of values to keys to make the intent
explicit (all the while knowing fully that, in Perl 5, a hash may
flatten to a list, an array w/ even number of elements will be
assigned to hash w/o problems, and '=>' is ornamental ','.)
- parv
--
In order to reach me, do away w/ WhereElse in the address.
A programmer, budding Unix system administrator, and amateur photographer
is in search of employment: http://www103.pair.com/parv/work/
------------------------------
Date: Thu, 17 Jul 2003 04:55:39 -0500
From: "Eric J. Roode" <REMOVEsdnCAPS@comcast.net>
Subject: Re: macros in perl
Message-Id: <Xns93BB3C48D4FCDsdn.comcast@206.127.4.25>
-----BEGIN xxx SIGNED MESSAGE-----
Hash: SHA1
marc0 <marc0@autistici.org> wrote in news:87n0fek5p7.fsf@autistici.org:
> I desire them because I desire to modify the syntax where IMHO makes
> sense, for example something like:
>
> #include <stdio.h>
>
> #define loop(n) for (i = 0; i < n; i++)
>
> int main ()
> {
> unsigned int i;
>
> loop (10)
> do_something ();
>
> return 0;
> }
>
> In the Perl script I'm working on I would use it to write something
> like
>
> #define walk_file(FILE) for ($walk_file_line = <FILE>)
>
> walk_file (FILE) {
> ...
> }
>
> and alike.
>
> That's not necessary but IMHO it helps to make the code more clear.
>
> Another way to do it would be to use the C preprocessor or M4 (likely
> better) on the file but this adds complexity.
IMNSHO, learn the goddamn language and use it. I once worked in a
department where some long-gone moron had written macros for making C
look like Pascal:
#define begin {
#define end }
#define or ||
#define not !
And so on. And then these macros were used -- inconsistently --
throughout much of the codebase. Far from making the code more clear, it
obfuscated the hell out of everything.
- --
Eric
$_ = reverse sort qw p ekca lre Js reh ts
p, $/.r, map $_.$", qw e p h tona e; print
-----BEGIN xxx SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
iQA/AwUBPxZylGPeouIeTNHoEQLpSwCeIa7wqp6AnDx7X5VaCksVxvlPRo8AnRMf
9OOQKLiduetHu2UmxpdJ/pyh
=lWTL
-----END PGP SIGNATURE-----
------------------------------
Date: Thu, 17 Jul 2003 09:09:06 GMT
From: "Ed W" <dodgynewsgroups@ewildgoose.demon.co.uk>
Subject: Re: Newbie OO question
Message-Id: <SItRa.362198$fC.2630720@news.easynews.com>
> perldoc perltoot
>
> it's all you need... that and maybe damian's book!:
>
> http://www.manning.com/Conway/
Thanks, I have read the perltoot page a few times, but it doesn't seem to
cover what happens if you want to inherit from an object that has, say, a
scalar as the underlying object storage, but I need somewhere to store some
extra object variables.
I suspect that there is something clever possible involving closures, but
since I'm not quite ready for that yet, I was just wondering if there was a
standard way out of this...
Thanks
Ed
------------------------------
Date: 17 Jul 2003 01:40:50 -0700
From: john_ramsden@sagitta-ps.com (John Ramsden)
Subject: Re: Opening a socket connection on a serial port
Message-Id: <d27434e.0307170040.4df0f19c@posting.google.com>
Darren Dunham <ddunham@redwood.taos.com> wrote in message news:<KzhRa.52$eS2.6211689@newssvr14.news.prodigy.com>...
> John Ramsden <john_ramsden@sagitta-ps.com> wrote:
> > I have a perl script that needs to control connects and
> > disconnects of a dialup connection, and transfer data via
> > a TCP socket stream opened on it. This must work on Windows
> > and Unix.
>
> [...]
>
> If the modem is not going to just give you ascii data, but is a normal
> dialup connection, then I think you don't want to be talking to the
> modem, but to the OS. You're going to have to signal to the OS that it
> should dial the modem and start a PPP connection.
I thought that would probably be the case. Devel::SerialPort seemed
too intricate and low-level for something just intended to start a
TCP/IP connection.
> I'm guessing there might be a windows module that could do something
> like that.
Does anyone know of a Win32 module that allows a perl script to open
a connection specifically via PPP, even if the PC is linked to other
networks?
> [...]
>
> > To put things in context, this requirement is for a security
> > hyperaware customer, who insists that the system on which my
> > monitoring package will runs must have no network link to the
> > outside world.
>
> Umm.. it sounds like you're trying to create a network link to
> the outside world, yes?
True, but it would be an exclusive link, and under the control
of the program. That's the customer's thinking anyway.
> > But as it may be linked to a local LAN, I can't assume the
> > modem will be the _only_ possibility for a socket connection
> > to use. Hence the need to somehow tie the socket open request
> > explicitly to the modem.
>
> Maybe you don't want a socket connection after all. Maybe you
> just want to dial the modem and treat it as an ascii device
> (like you're connecting to a BBS rather than a PPP server).
Could well be - my app sends data one way, which simplifies things.
But then I'd presumably need a separate process at the other end
to read the data and pass it via TCP to the receive program. So
that adds a slight complication and potential point of failure.
On reflection, it's looking like PPP might be simpler overall,
provided I can direct a TCP socket request to the PPP directly,
even if this is not the default connection, and also disconnect
the connection under program control.
Anyway, many thanks for your prompt reply, and if you have any
further thoughts don't hesitate ...!
Cheers
John Ramsden (john_ramsden@sagitta-ps.com)
------------------------------
Date: 17 Jul 2003 01:48:30 -0700
From: john_ramsden@sagitta-ps.com (John Ramsden)
Subject: Re: Opening a socket connection on a serial port
Message-Id: <d27434e.0307170048.4f8bff35@posting.google.com>
efflandt@xnet.com (David Efflandt) wrote in message news:<slrnbhbce2.nug.efflandt@typhoon.xnet.com>...
> On 16 Jul 2003 09:37:49 -0700, John Ramsden <john_ramsden@sagitta-ps.com> wrote:
> > I have a perl script that needs to control connects and
> > disconnects of a dialup connection, and transfer data via
> > a TCP socket stream opened on it. This must work on Windows
> > and Unix.
> >
> > (Question in passing: Does Devel::SerialPort work on Windows
> > as well as Unix? The documentation says it was derived for
> > POSIX from Win32::SerialPort.)
>
> Device::SerialPort is a Unix port of Win32::SerialPort. So you use
> Win32::SerialPort in Windows, and Device::SerialPort in Linux or Unix.
Ah, OK. Sounds reasonable.
> While that could chat with a modem, dialout to a shell, communicate
> with a shell, it will NOT do TCP/IP.
>
> TCP/IP would work easiest (transparently) if the user already had an
> automatic PPP connection set up in Windows DUN, or demand pppd set up in
> Unix.
>
> Otherwise, if you are trying to initiate the PPP connection from your
> script, I know how to do that in Linux or FreeBSD
If this is fairly simple, and remotely perl-ish, would there be any
chance of posting a summary or a pointer?
> [...]
Many thanks for your reply. I'm gradually getting an idea of roughly
what is required; so now it's just a matter of sussing out the details.
Cheers
John Ramsden (john_ramsden@sagitta-ps.com)
------------------------------
Date: 16 Jul 2003 18:38:19 -0700
From: rook_5150@yahoo.com (Bryan Castillo)
Subject: Re: Problem executing a BAT file (or EXE file) using Perl as CGI script under Apache.
Message-Id: <1bff1830.0307161738.7f218562@posting.google.com>
Cat <cat@no-spam.com> wrote in message news:<3F13F618.64805F5D@no-spam.com>...
> Tom Salzmann wrote:
> >
> > I have developed some perl code to run as a script under Windows 2000
> > running apache. This works GREAT on Win2k but on WinNT, perl is simply
> > unable to launch the program. The program works fine from the command line.
> >
> > Here's the code:
> >
> > $fred=time . ".out" ;
> > open(OUTPUT, "|imon.bat " . $fred . " " . $ENV{'REMOTE_ADDR'} . " " .
> > $IMCommand . " " . $IMFile );
> > close OUTPUT;
> > open(FILE, $fred );
> > @htmlLines = <FILE>;
> > close FILE ;
> > unlink($fred);
> > unlink($IMFile);
> >
> > As a test to make sure I wasn't nuts, I put the following in the bat file:
> >
> > ECHO >> echo.out
> >
> > And sure enough, I get "ECHO IS ON" in the file every time I run from
> > command line. But when I run from Apache, I get NOTHING. It's as if Apache
> > is unable to launch the thing.
> >
> > Again, this works FINE under Win2k but fails on WinNT - Any ideas? I tried
> > system() but I get the same thing.
> >
> > Thanks,
> >
> > Tom
>
> Check the Apache log files for clues
> Include the full path to imon.bat and see if that works
---------
Did you try this ^^^ ? (to the original poster)
> Maybe try hard coding the parameters to imon.bat or simplifying it
> eg open(OUTPUT, "|imon.bat 1234.out 127.0.0.1 echo test.txt");
>
> inet.bat can be something like
>
> ECHO %1 %2 %3 %4 >> echo.out
------------------------------
Date: Thu, 17 Jul 2003 04:40:59 GMT
From: Brendan Byrd/SineSwiper <SineSwiper@ResonatorSoft.org>
Subject: Removing Perl comments and strings using regexps
Message-Id: <vNpRa.68764$wk6.17432@rwcrnsc52.ops.asp.att.net>
I'm in the middle of fixing the LXR tool to work with Perl. Almost
finished, but I've ran into a problem that completely fries my brain.
In order to detect Perl subroutine/variable declarations, I need to
remove comments and strings so that they don't get confused for
declarations.
My current code works for most cases:
# Remove escaped/variable characters for strings/comments
$contents =~ s/\\\$//g;
$contents =~ s/[\\\$][\"\'\#]//g;
# Remove literal strings
$contents =~ s/\"[^\"]*?\"//gs;
$contents =~ s/\'[^\']*?\'//gs;
# Remove comments
$contents =~ s/\#[^\n]*//g;
However, if you run into a comment with a quotemark, it screws up
everything:
# I'll be back
I can switch the order of the removes, but then I encounter the reverse
problem: a string with a pound sign.
$aaa = '#FF0088';
The remove comment line kills the second quote mark, and the remove
string then runs away and gobs up everything in sight (until you have
another string with the same pound sign problem). Is there any sort of
regexp that would work for this program:
# Sine's program
$aaa = 'test #'; # test statement
$bbb = 'halo #
there'; # multi-line using ' marks
# #'#'#'#''######'
--
Brendan Byrd/SineSwiper <SineSwiper@ResonatorSoft.org>
Perl hacker, computer wizard, and all-around internet guru
Resonator Software <http://www.ResonatorSoft.org/>
------------------------------
Date: Thu, 17 Jul 2003 05:03:30 GMT
From: tiltonj@erols.com (Jay Tilton)
Subject: Re: Removing Perl comments and strings using regexps
Message-Id: <3f162da5.13263740@news.erols.com>
Brendan Byrd/SineSwiper <SineSwiper@ResonatorSoft.org> wrote:
: I'm in the middle of fixing the LXR tool to work with Perl. Almost
: finished, but I've ran into a problem that completely fries my brain.
: In order to detect Perl subroutine/variable declarations, I need to
: remove comments and strings so that they don't get confused for
: declarations.
How about just running the program through the Xref backend?
perl -MO=Xref foo.pl
------------------------------
Date: Thu, 17 Jul 2003 04:49:42 -0500
From: "Eric J. Roode" <REMOVEsdnCAPS@comcast.net>
Subject: Re: Removing Perl comments and strings using regexps
Message-Id: <Xns93BB3B46952ABsdn.comcast@206.127.4.25>
-----BEGIN xxx SIGNED MESSAGE-----
Hash: SHA1
Brendan Byrd/SineSwiper <SineSwiper@ResonatorSoft.org> wrote in
news:vNpRa.68764$wk6.17432@rwcrnsc52.ops.asp.att.net:
> I'm in the middle of fixing the LXR tool to work with Perl.
LXR tool?
[...]
> Is there any sort of
> regexp that would work for this program:
>
> # Sine's program
> $aaa = 'test #'; # test statement
> $bbb = 'halo #
> there'; # multi-line using ' marks
> # #'#'#'#''######'
Don't forget constructs like:
$str = q#He said, "It's great!"#;
$str =~ s#'#''#; # substitution
$str =~ s#"'"#'"'#;
$str =~ m#\##;
Have you looked at B::Deparse to do the work for you?
- --
Eric
$_ = reverse sort qw p ekca lre Js reh ts
p, $/.r, map $_.$", qw e p h tona e; print
-----BEGIN xxx SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
iQA/AwUBPxZxIWPeouIeTNHoEQJfogCgiraoJ0ZJX7Oa11H6Mgsk9LYVRmAAoN7m
GCHWy5ouK11HyZIn8DV+VPaZ
=QQay
-----END PGP SIGNATURE-----
------------------------------
Date: Thu, 17 Jul 2003 02:01:31 -0400
From: "Brian Berneker" <brianberneker@hotmail.com>
Subject: Test for file existence
Message-Id: <bf5e3v$v7j$1@news1.mountaincable.net>
File existence test is simple
if (-e "filename") { whatever }
------------------------------
Date: 17 Jul 2003 07:03:17 GMT
From: "Tassilo v. Parseval" <tassilo.parseval@rwth-aachen.de>
Subject: Re: Test for file existence
Message-Id: <bf5hnl$93a$1@nets3.rz.RWTH-Aachen.DE>
Also sprach Brian Berneker:
> File existence test is simple
>
> if (-e "filename") { whatever }
Most fascinating. Care to tell us what you are talking about here (and
in the other orphaned post)?
Tassilo
--
$_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
$_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval
------------------------------
Date: Thu, 17 Jul 2003 07:39:15 GMT
From: "Gregory Toomey" <nospam@nospam.com>
Subject: Re: Test for file existence
Message-Id: <DosRa.141$OM3.11@news-server.bigpond.net.au>
"Brian Berneker" <brianberneker@hotmail.com> wrote in message
news:bf5e3v$v7j$1@news1.mountaincable.net...
> File existence test is simple
>
> if (-e "filename") { whatever }
Good. What does it say on page 2 of "Learning to Program"?
gtoomey
------------------------------
Date: Thu, 17 Jul 2003 04:58:33 -0500
From: "Eric J. Roode" <REMOVEsdnCAPS@comcast.net>
Subject: Re: Use module (maybe) w/o dying
Message-Id: <Xns93BB3CC69DC53sdn.comcast@206.127.4.25>
-----BEGIN xxx SIGNED MESSAGE-----
Hash: SHA1
gnarred@yahoo.com (gnarred) wrote in
news:2edd058c.0307151937.1d4a2720@posting.google.com:
> Modules are just Perl files that exist in the paths defined in @INC.
> So you can step through @INC, and test if the modules exist:
>
> BEGIN {
> our $module = 'Carp';
> for my $i (@INC) {
> if (-e "$i/$module.pm") { # does module file exist?
> require "$i/$module.pm";
> $module->import();
> }
> }
> }
>
> That should take care of it!
Unless your module name is, say, CGI::Carp.
You need to do
s!::!/!g;
first.
- --
Eric
$_ = reverse sort qw p ekca lre Js reh ts
p, $/.r, map $_.$", qw e p h tona e; print
-----BEGIN xxx SIGNATURE-----
Version: PGPfreeware 7.0.3 for non-commercial use <http://www.pgp.com>
iQA/AwUBPxZzQmPeouIeTNHoEQLD+gCggVEKP5qmQ0C6CJ+bAJOJ46EX8OUAnisZ
ycba5b3Ox4b8hCugl6DI3ng1
=rZcF
-----END PGP SIGNATURE-----
------------------------------
Date: Wed, 16 Jul 2003 23:18:43 +0100
From: Chad Hanna <chad@vellum.demon.co.uk>
Subject: Re: Using Perl / MYSQL for a large database application
Message-Id: <xuZYXoWD9cF$EwIN@vellum.demon.co.uk>
In message <68838fa1.0307161354.6fbecde@posting.google.com>, mapexvenus
<mapexvenus2002@yahoo.com> writes
>Hi,
>We are in the process of building an application to front end a
>database of about 2 million records. I would like to know if MYSQL /
>Perl on Linux can handle this and if not, what would be a good
>database to go with. We would like to use opensource as much as
>possible, but if MYSQL cannot handle this kind of volume then we will
>have to go in for commercial software.
>
>Thanks,
Should be no problem with a relatively small database like this - as
long as you index your tables. More to the point what is your query
rate, how much memory can you devote to caching and how? Are you
planning to use mod_perl rather than CGI?
We're up to nearly 20 million records with 7 indexes on one table on
MySQL 3.23.49 FreeBSD 4.6, Apache 1.3.27 and mod_perl 1.27 - and I'm now
planning for 60 million records with freetext searches on MySQL 4.
Of course, issues can arise, but there are lots of documents, including
the reference manual and an active email list which is perhaps a better
place for this sort of discussion - See:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
Cheers, Chad
--
Chad Hanna
Chairman Berkshire Family History Society www.berksfhs.org.uk
Quality Family History Data www.familyhistoryonline.net
------------------------------
Date: Thu, 17 Jul 2003 02:16:21 GMT
From: "Gregory Toomey" <nospam@nospam.com>
Subject: Re: Using Perl / MYSQL for a large database application
Message-Id: <VFnRa.7675$wU5.2078@news-server.bigpond.net.au>
"mapexvenus" <mapexvenus2002@yahoo.com> wrote in message
news:68838fa1.0307161354.6fbecde@posting.google.com...
> Hi,
> We are in the process of building an application to front end a
> database of about 2 million records. I would like to know if MYSQL /
> Perl on Linux can handle this and if not, what would be a good
> database to go with. We would like to use opensource as much as
> possible, but if MYSQL cannot handle this kind of volume then we will
> have to go in for commercial software.
>
> Thanks,
I've got a much larger database of stock exchange prices and Perl/dbi/mysql
handles it with no problems.
Its a matter of using the right indexes and right
normalisation/denormalisation.
Note that mysql is very primative at the moment - subqueries & views are
just being added. But mysql is VERY fast. Postgres may be a better choice.
Oracle is an option too, Linux licencing of Oracle can be cheaper than other
platforms.
gtoomey
------------------------------
Date: 17 Jul 2003 05:09:35 GMT
From: Martien Verbruggen <mgjv@tradingpost.com.au>
Subject: Re: Using Perl / MYSQL for a large database application
Message-Id: <slrnbhcbsh.1rf.mgjv@verbruggen.comdyn.com.au>
On 16 Jul 2003 14:54:19 -0700,
mapexvenus <mapexvenus2002@yahoo.com> wrote:
> Hi,
> We are in the process of building an application to front end a
> database of about 2 million records. I would like to know if MYSQL /
> Perl on Linux can handle this and if not, what would be a good
> database to go with. We would like to use opensource as much as
> possible, but if MYSQL cannot handle this kind of volume then we will
> have to go in for commercial software.
\begin{offtopic}
2 million records is not much. MySQL can easily deal with that.
There is, however, no reason to go for other commercial software [1]
if you have a task that MySQL doesn't perform well for certain tasks.
PostgreSQL is a very decent RDBMS, and for almost all tasks equal
to, or better than MySQL.
[1] You do know that MySQL _is_ a commercial product as well as being
available under open source licenses?
\end{offtopic}
The size of your database has very little to do with whether Perl/DBI
can "handle" it. How much data you process outside of the database,
and what you do with it, and what the requirements are on timing and
stuff could have something to do with it. I generally find that using
a native (native to the RDBMS) C library with a C application tends to
be fastest, and least memory hungry. On the other hand, Perl with DBI
uses more resources and CPU, but is much, much easier to write and
maintain. Most of the utilities and reporting programs we write are in
Perl, nowadays.
Martien
--
|
Martien Verbruggen | That's funny, that plane's dustin' crops
Trading Post Australia | where there ain't no crops.
|
------------------------------
Date: 17 Jul 2003 04:48:25 GMT
From: "Tassilo v. Parseval" <tassilo.parseval@rwth-aachen.de>
Subject: Re: Where are the perl folks?
Message-Id: <bf59qp$35j$1@nets3.rz.RWTH-Aachen.DE>
Also sprach Eric J. Roode:
> Something's amiss.
>
> The comp.lang.perl.announce moderators don't seem to be around anywhere. I
> posted a message there a couple weeks ago; it hasn't shown up. I sent a
> followup email asking about status, but it has so far been unanswered.
>
> No new modules / namespaces have been accepted by pause.perl.org in a
> couple weeks. Someone posted a question asking about this to
> modules@perl.org, and it has gone unanswered.
Those are things that require human interference. Right now a lot of
conferences are going on and everyone seems to be on one or the other.
That should be over soon (hmmh, but then YAPC::Europe begins).
Anyway, in general I noticed that, too. I still have two not yet applied
patches in the p5p-queue. But patience usually pays off.
> I tried to join perl5-porters a week or two ago. I sent a blank email to
> the address specified at dev.perl.org, and nothing has happened -- no
> confirmations, no rejections, and no mailing list messages.
That is odd. This mailing-list is handled by ezmlm so you should at
least get an automatic reply. Did you use the address
<perl5-porters-subscribe@perl.org>?
Tassilo
--
$_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
$_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval
------------------------------
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 5231
***************************************