473,387 Members | 1,485 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Executing a function declared in Oracle Package from Unix shell script:-

Hi,

Can anyone tell me how to execute a function declared in Oracle Package from Unix shell script?

I created a shell script and after connecting to oracle database i am using
exec @ Db_name.Packagename.function_name('p1','P2');

and after executing the shell scripts i am getting the follwing error:-ERROR at line 13:
ORA-06550: line 13, column 2:
PLS-00221: 'function_name' is not a procedure or is undefined
ORA-06550: line 13, column 2:
PL/SQL: Statement ignored


Can anyone help me out as how to execute a function?
Your suggestion will be Highly appreciated.
Oct 17 '07 #1
2 10269
Motoma
3,237 Expert 2GB
I have bumped this thread over to the Oracle forum, as I feel this is more related to the use of Oracle and it's specific tools than Unix.
Oct 18 '07 #2
amitpatel66
2,367 Expert 2GB
Hi,

Can anyone tell me how to execute a function declared in Oracle Package from Unix shell script?

I created a shell script and after connecting to oracle database i am using
exec @ Db_name.Packagename.function_name('p1','P2');

and after executing the shell scripts i am getting the follwing error:-ERROR at line 13:
ORA-06550: line 13, column 2:
PLS-00221: 'function_name' is not a procedure or is undefined
ORA-06550: line 13, column 2:
PL/SQL: Statement ignored


Can anyone help me out as how to execute a function?
Your suggestion will be Highly appreciated.
When executing a procedure, just say EXEC dbname.package.function_name(<parameters>);
@ is not required.

The error says function_name is not a procedure or undefined.
Could you please POST your package/package body for my reference.
It seems that the procedure/function with name function_name is not defined in a package or under db_name!!
Oct 19 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Nick Coghlan | last post by:
Anyone playing with the CPython interpreter's new command line switch might have noticed that it only works with top-level modules (i.e. scripts that are directly on sys.path). If the script is...
15
by: Nick Coghlan | last post by:
Python 2.4's -m command line switch only works for modules directly on sys.path. Trying to use it with modules inside packages will fail with a "Module not found" error. This PEP aims to fix that...
2
by: RJ | last post by:
We currently send product releases to our customers, and often have to include scripts that need to be ran on the Oracle databases (also do it for SqlServer customers, but we use a different set of...
4
by: chris.dunigan | last post by:
I'm looking for an example of how to execute an existing DTS­ package from an ASP (VB)script and would appreciate any and all response. ­I don't even know if it's possible Thanks - Chuck...
19
by: DW | last post by:
Hi, all... I have a sizeable database running under Oracle 9.2.0.4 under AIX 5.2.0. I am faced with an impending move to a Windows environment, running under SQL 2000. Currently, we are...
10
by: Noah | last post by:
I would like to package my main script and all the modules it imports into a single script that will run just as the collection would. It should not need to package standard Python lib modules --...
6
by: Sanket80 | last post by:
Hi, I have one shell script which runs a report and sends the output to user. The shell script has some queries written in it in SQL and hence when I execute a shell script via a concurrent...
0
by: truthbajaj | last post by:
Hi, I am using Oracle 9i and Unix on my system and trying to execute a UNIX shell command through external procedure in C. I created a shared lib (libextproc.so) for the following function. ...
1
by: ora2000 | last post by:
Hi I would like to create a unix script to connect to an ORACLE database using a oracle package. Also this script should provide functionality to call an oracle procedure that contains a parameter...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.