My Remarks!

the Life, the Universe and almost Everything what's Left

Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in /mnt/web018/d2/82/51207682/htdocs/armbruster-it/joomla33/templates/stefans_blog_05/functions.php on line 182

How to Java programming in Oracle Database

info-14This article is about how Java programs can be developed directly in the Oracle database and in particular, it shows an example how to access the file system of the operating system. Since the Oracle version 8, it is possible to write Java code direct within the database. So it would be possible, to write stored procedures with Java instead of using PL/SQL. Nevertheless, the advantages of PL/SQL are the safe and stable processing of mass data, so there is no need to change to Java in this part. But if we have issues who are located outside of the database, we will reach the limits of PL/SQL very quickly. This is the point where Java starts, because the language itself is independent of the operating system and therefore it is predestined for tasks like this. In addition, we can rely on a vast range of finished Java solutions, who can than operate within the Oracle database. Maybe there are a few slightly modifications needed but in general it is not a big deal.

However, a weak point of this is the actuality of Java! The version within the database is "lagging" behind the current versions. This is because that a stable Java version is the base of the development of a new database release. While this new release than is productive for years, there are no changes in the internal version of Java, whereas the Java world outside of the Oracle database has already seen significant developments. The result is, that a Oracle version 11.2, which is very common right now (the first release dates from 2007), has the Java Runtime version 1.5.0_10 (2005!) included.

The entire source code of the directory list example you will find here!

 

 

Stored Procedures with Java?

The most common language within the Oracle database is still PL/SQL. This is the prefered language to develop Stored Procedures, Packages or Triggers. In order to develop with Java, the Java sources must be uploaded into the database. From this, the classes are extracted and displayed in the Data Dictionary as a schema object. It allows Java sources (.java) and class files (.class) or archives (.jar, .zip) to be uploaded.

Read more: How to Java programming in Oracle Database

Visits

Today 57 | Week 464 | Month 1726 | All 1112000

Challenges Completed

Vätternsee Club des Cinglés du Mont-Ventoux Styrkeproven 24hVelo Belchen³ Guitar Rehearsal

StackOverflow

profile for PT_STAR at Stack Overflow, Q&A for professional and enthusiast programmers