can use the following like overloading concept in a single
package:
procedure p1(a varchar),
procedure p1(a varchar2),
procedure p1(a char)
Answer Posted / bunty
Yes. you can create package where overloading will be
identified by using type of arguments.
Following code will work fine,
--WORK's FINE
create or replace package PK_TEST AS
procedure p1(a IN varchar);
procedure p1(a IN varchar2);
procedure p1(a IN char);
end PK_TEST;
But,following code will not work as p1( v1 IN varchar) and
p1(v3 IN varchar) has the same type of arguments.
--NOT WORK
create or replace package PK_TEST AS
procedure p1(v1 IN varchar);
procedure p1(v2 IN varchar2);
procedure p1(v3 IN varchar);
end PK_TEST;
Cheers,
Bunty
| Is This Answer Correct ? | 3 Yes | 3 No |
Post New Answer View All Answers
differentiate between float and double. : Sql dba
How to use sql*plus built-in timers?
Is sql database free?
What is materialized view. What are different methods of refresh?
how to implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql dba
What are types of indexes in sql?
Why schema is used in sql?
what are date and time intervals? : Sql dba
Why is sql important?
What are the constraints available in sql?
What is the difference between sql, mysql and sql server?
Why indexing is needed?
How is a process of pl/sql compiled?
Explain the types of joins in sql?
Why we use joins in sql?