Home » SQL & PL/SQL » SQL & PL/SQL » ORA-14551 and INSERT INTO
ORA-14551 and INSERT INTO [message #434705] Thu, 10 December 2009 05:21 Go to next message
joshua82
Messages: 31
Registered: December 2009
Member
I need to do a query which calls a function. This function performs a INSERT INTO..

When I'm testing this situation creates an error:
ORA-14551: cannot perform a DML operations inside a query

How can I solve this?
Thanks
Re: ORA-14551 and INSERT INTO [message #434708 is a reply to message #434705] Thu, 10 December 2009 05:25 Go to previous messageGo to next message
Michel Cadot
Messages: 68737
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Do not call the function with a SELECT, call it with a PL/SQL block.

Regards
Michel
Re: ORA-14551 and INSERT INTO [message #434714 is a reply to message #434705] Thu, 10 December 2009 05:41 Go to previous messageGo to next message
delna.sexy
Messages: 941
Registered: December 2008
Location: Surat, The Diamond City
Senior Member
Read : Restrictions on User-Defined Functions
on
http://www.stanford.edu/dept/itss/docs/oracle/10g/server.101/b10759/statements_5009.htm

regards,
Delna
Re: ORA-14551 and INSERT INTO [message #434717 is a reply to message #434708] Thu, 10 December 2009 05:48 Go to previous message
joshua82
Messages: 31
Registered: December 2009
Member
Michel Cadot wrote on Thu, 10 December 2009 05:25
Do not call the function with a SELECT, call it with a PL/SQL block.

Regards
Michel

Great! Thanks
Previous Topic: Using WITH Clause
Next Topic: "Create table from another Table" issue
Goto Forum:
  


Current Time: Sun Feb 16 00:36:31 CST 2025