Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: PERL?

Re: PERL?

From: Mladen Gogala <mgogala_at_adelphia.net>
Date: Sun, 07 Dec 2003 21:04:26 -0800
Message-ID: <F001.005D91F2.20031207210426@fatcity.com>


Perl is a general purpose interpreted programming language, written specifically with reporting purpose in mind. In fact, perl stands for "Practical Extraction/Reporting Language". That means that perl is excellent for producing all kinds of reports. In fact, it has a part called "formats" which is, in fact, a small report writer and can be used to produce beautiful reports very quickly and with minimal effort. The next very useful feature is an extremely versatile regular expression engine which can do whatever awk & sed can do and more. That, of course, is ideal for parsing all kinds of regular expressions, like, for instance, parsing alert.log. Perl , as I've said before, is a general purpose programming language with pointers (all right, all right, the name is "references", but those are really pointers) , which makes for an exceptionally powerful combination. Last, but not least, there is a huge treasure chest called "CPAN" (http://cpan.perl.org) which contains vast number of modules. In case of emergency, it's really easy to find something useful. One other thing worth mentioning is that perl has bindings and modules which make it possible to work with many databases, Tk, Gtk, HTML and almost anything conceivable (OLE, ODBC, ADO and other MS perversions included). There are two problems with perl. One is that perl is a huge language with so many intrinsic and important elements that it is really hard to learn the whole language. A title of a perl master should be an equivalent of a PhD. Another problem is a serious inadequacy of perl syntax for OO. Perl doesn't have classes, abstract classes, private/protected/public interface, templates, exception throw/catch mechanisms or some other things that we know and love. Perl's OO model is based on something called "module", essentially a program unit and a very weird function named "bless". This function plays a vital role in object construction and, it is done from up down to the ground instead of doing it from the ground up. Bless takes a pointer ("reference") and "blesses" it to the pointer to a member of a given class. That means that whatever the pointer is pointing to, becomes a class member. It is exactly like taking a stem and creating an apple or a pear at its end, depending on the need of the moment. Function "new" doesn't exist. There is no official constructor and there is no official destructor. Destroying objects is based on reference counting which is fast, much faster then Java background garbage collection, but also unreliable because it can be easily prevented. If you want a web version of perl, with a proper syntax and a smaller number of inscrutable undocumented language features, try PHP.

On 2003.12.07 22:34, KENNETH JANUSZ wrote:
> I've read a lot about PERL on this list. And, I am wondering what can you do with PERL that you cannot do with SQL*Plus, PL/SQL or Unix shell scripts?
>
> Any information will be greatly appreciated.
>
> Thanks much,
> Ken Janusz, CPIM

-- 
Mladen Gogala
Oracle DBA
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Mladen Gogala
  INET: mgogala_at_adelphia.net

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Sun Dec 07 2003 - 23:04:26 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US