oracle - Get the DDL for a function in a package -


is there way ddl function in package under different user in oracle? can see package in sql developer under 1 of users listed under 'other users'. i've tried using dbms_metadata.get_ddl function:

select dbms_metadata.get_ddl('package', 'my_package', 'other_user') dual 

but following error:

ora-31603: object "my_package" of type package not found in schema "other_user"

for first parameter of get_ddl function tried package_spec, , package_body didn't seem help.

not sure if anyone, old question, use query (from java) rip procedures , functions off our server can put them in git. i'm using 12c.

with x  (   select owner, object_name, object_type     dba_objects   owner 'owner_name_here'     , object_type in ('procedure',  'function') ) select  dbms_metadata.get_ddl (x.object_type, x.object_name, x.owner) ddlcode x; 

Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

php - Best Light server (Linux + Web server + Database) for Raspberry Pi -

c# - "Newtonsoft.Json.JsonSerializationException unable to find constructor to use for types" error when deserializing class -