1

I am using (with function) in Oracle 12c. in 11g this is not available. Is there any other way we can implement with function in 11g?

with 
 function x(p_NUM in number) return number
 is
 n number;
 begin
 SELECT 1 INTO N FROM DUAL;
 --
 return N;
 --
 end ; 
 -- 
 function Y(p_NUM in number) return number
 is 
 N1 NUMBER;
 begin
 SELECT 2 INTO N1 FROM DUAL;
 --
 return N1;
 --
 end ; 
--
select X(1), Y(1)
from dual;
48347
1082 gold badges7 silver badges26 bronze badges
asked Aug 27, 2019 at 17:24
1
  • I think it depends what the functions does. if it's simple, then we have some options, some Oracle DBMS packages, built-in functions. Commented Aug 27, 2019 at 20:33

1 Answer 1

2

Create the functions within a PACKAGE.

Beyond that, you are using a feature that was introduced in 12c.

answered Aug 27, 2019 at 23:07

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.