if i am using dml statement in function.
then i am writing select statement what was the output
Answer Posted / sandeeptiwari1111@gmail.com
We can perform DML operation in function but we can not Query that function in select statement.
But if you want to query it any how from select stmnt then you have to use Pragma_autonomous transaction .
create or replace function f2 return date as
Pragma Autonomous_Transaction;
begin
insert into Tab values(sysdate);
commit;
return sysdate-1;
end ;
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Can we call procedure inside function in oracle?
what is the difference between data migration and production migration.
How to define a cusotmer as a supplier in ORACLE R12
What is bulk load in oracle?
What is the quickest way to fetch the data from a table?
How to apply filtering criteria at group level in oracle?
How to handle a single quote in oracle sql?
Can we convert a date to char in oracle and if so, what would be the syntax?
How do we display rows from the table without duplicates?
Is a rollback possible to any savepoint?
What is user managed backup in Oracle?
How to define default values for formal parameters?
How to concatenate two text values in oracle?
What operating systems are supported by oracle database 10g xe?
Why cursor variables are easier to use than cursors?