How to import a Java Jar to Oracle Forms


The steps involved are simple as below:

1. Save the jar file where forms jar files are saved
   Usually {FormsInstalledPath}\forms\java folder

2. Open Registry editor (REGEDIT)
   Browse to the following Key
   HKEY_LOCAL_MACHINE/SOFTWARE/ORACLE/KEY_DevSuiteHome1

3. Add Java archive name in the Name FORMS_BUILDER_CLASSPATH
 

4. Now open Form Builder and create new form.


5. Open Menu Program > Import Java Classes and find your java class added and Import.

Enjoy

CSV data to multiple rows - Oracle Query

I have a data in CSV format (comma separated values) like follows:

first,second,third,fourth,fifth 

I want the output as follows:
column_value
first
second
third
fourth
fifth

The easiest way to achieve is to use a CONNECT BY clause in DUAL table and to populate the results. Here is the query:


SELECT substr(str, instr(str, ',', 1, LEVEL) + 1, instr(str, ',', 1, LEVEL + 1) - instr(str, ',', 1, LEVEL) - 1) column_value
FROM   (SELECT ',' || '&mystring' || ',' str FROM dual)
CONNECT BY LEVEL <= length(str) - length(REPLACE(str, ',')) - 1;


Pass value first,second,third,fourth,fifth to mystring.