Issues with Java Stored Procedure and os commands using wildcards and references to the $Oracle_home/Dbs directory.

(Doc ID 819366.1)

Last updated on JULY 05, 2017

Applies to:

Oracle Server - Enterprise Edition - Version: and later   [Release: 10.2 and later ]
Information in this document applies to any platform.
This code was tested in and


There are two issues that can appear when using a Java Stored Procedure to interact with the operating system (OS).

The first issue is when using a Java Stored Procedure to interact with the files on the OS works when specific files are referenced, but incorporating the asterisk '*' as a wildcard has no affect.
This means when executing commands like "ls myfile.txt" will work but requests like "ls *.txt" will not.

The second issue is when a particular directory is being referenced the $ORACLE_HOME/dbs directory is always included. This means when executing the "ls /tmp", files from the $ORACLE_HOME/dbs directory will be included in the output.


Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms