> CREATE OR REPLACE FUNCTION FACTORIAL_1(factstr varchar2
)
2 RETURN NUMBER AS
3 new_str VARCHAR2(4000) := factstr||'*' ;
4 fact number := 1 ;
5 BEGIN
6
7 WHILE new_str IS NOT NULL
8 LOOP
9 fact := fact *
TO_NUMBER(SUBSTR(new_str,1,INSTR(new_str,'*')-1));
10 new_str := substr(
new_str,INSTR(new_str,'*')+1);
11 END LOOP;
12
13 RETURN fact;
14
15 END;
explanation Above program?


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More Oracle General Interview Questions

How to resolve the ORA-39133 error in Oracle?

0 Answers  


Explain can a view based on another view?

1 Answers  


Whether any commands are used for months calculation? If so, what are they?

0 Answers  


How can you Enforce Referential Integrity in snapshots ?

1 Answers  


Give the Types of modules in a form?

1 Answers  


How to assign a table row to a record variable?

0 Answers  


What is a read write transaction in oracle?

0 Answers  


How to retrieve values from data fields in record variables?

0 Answers  


Database crashes. Corruption is found scattered among the file system neither of your doing nor of Oracles. What database recovery options are available? Database is in archive log mode.

0 Answers  


Why does Oracle not permit the use of PCTUSED with indexes?

0 Answers  


How to store only time; not date and time?

0 Answers  


how to find the second highest salary in a given table????

5 Answers  


Categories
  • Oracle General Interview Questions Oracle General (1808)
  • Oracle DBA (Database Administration) Interview Questions Oracle DBA (Database Administration) (261)
  • Oracle Call Interface (OCI) Interview Questions Oracle Call Interface (OCI) (10)
  • Oracle Architecture Interview Questions Oracle Architecture (90)
  • Oracle Security Interview Questions Oracle Security (38)
  • Oracle Forms Reports Interview Questions Oracle Forms Reports (510)
  • Oracle Data Integrator (ODI) Interview Questions Oracle Data Integrator (ODI) (120)
  • Oracle ETL Interview Questions Oracle ETL (15)
  • Oracle RAC Interview Questions Oracle RAC (93)
  • Oracle D2K Interview Questions Oracle D2K (72)
  • Oracle AllOther Interview Questions Oracle AllOther (241)