Perl and Oracle has not always an easy past. Depending on the OS type and Oracle Version it can be quite nerve racking to compile DBI and DBD::Oracle. In addition to DBD::Oracle there are also other binary Perl modules that are not so easy to compile. On operating systems such as Microsoft Windows it is necessary to invest a little more effort to compile Perl. Alternatively one can use precompiled packages like Active Perl or Strawberry Perl. But this is basically not necessary at all if Oracle is already installed. Since Oracle 10g Perl is part of the Oracle binaries for the client and Database server. Oracle does use it for various tools itself. This allows it to easily create and execute custom perl scripts even on an Oracle Client installation. I do this regularly when I create Oracle Database security reviews. Instead of manually collecting all sorts of information, I’m running a few Perl scripts. This also works if I only have access to an Oracle client installation.
Available Perl Versions
Consequently, the different Oracle versions contains different versions of Perl. With the latest Oracle Database 12c Release 1 it just got update.
- Oracle 10g Release 2 contains Perl 5.8.3
- Oracle 10g Release 2 contains Perl 5.10.0
- Oracle 12c Release 1 contains Perl 5.14.1
As you see this are not realy the latest stable version of Perl. The following Picture show’s the latest release for each branch of Perl.
Depending on what you want to do with Perl, this is generally not a problem. Nevertheless, it is useful to check what is supported in the corresponding release or not.
With perldoc you’ll get all kind of perl documentation. For instance the user contributed perl modules aka additional perl modules
With corelist you’ll get information on core perl modules perl.
utf8 was first released with perl 5.006
But before you start to develop your big perl applications be aware, that you shouldn’t relay on it. According to the Oracle Metalink Note 342754.1 You should not use it for your own applications.
Note:- Perl and other 3rd party tools such as the Sun JRE are provided in the ORACLE_HOME for Oracle tool usage only. PERL libraries which are part of the Oracle RDBMS CD (Client / Database) are not meant for PERL custom application development, but they are used by various Oracle tools that are shipped along with Oracle RDBMS software such as EM DB Console etc.,
Using it for just a bunch of admin and reports scripts it shouldn’t be a big issues. Especially because you save quite some time when you not have to install Perl and DBD::Oracle yourself.
How tu use it
A few example how to use it will follow later on…
Some links related to this post.
- Perl Source Readme on CPAN with information on the latest version on each branch of Perl
- DBI – Database independent interface for Perl
- DBD::Oracle Oracle database driver for the DBI module
- Oracle Support of PHP, Perl, DBD/DBI and other 3rd party products [342754.1]
- Active Perl from ActiveState
- Strawberry Perl