Home » SQL & PL/SQL » SQL & PL/SQL » Which to use to update db: Cursors or Record passing ?
Which to use to update db: Cursors or Record passing ? [message #39517] Mon, 22 July 2002 04:11 Go to next message
Mark Grimshaw
Messages: 73
Registered: June 2002
Member
Hello,

I need to update one or more ros returned from a table
using client programs written using PL/SQL blocks inserted in Fortran client code.

I had considered Stored Procedures returning/receiving PL/SQL RECORD types so that client code is not littered with DML statements. However, where multiple record updates are concerned would I not be better (more efficient) returning Cursor Variables from Stored procedures and updating the tables rather than repeatedly sending records to an update procedure ?

Mark Grimshaw
Re: Which to use to update db: Cursors or Record passing ? [message #39528 is a reply to message #39517] Mon, 22 July 2002 09:48 Go to previous message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
What about sending an array (PL/SQL table) of the ids to be updated into a stored procedure and then using FORALL to do the update? This is assuming that you are applying the same update to all of the ids (wasn't sure if this was the case or not from your description).
Previous Topic: Passing Parameters from Ref_Cursors SPs to C ++ Pgms
Next Topic: passing parameters from PL/SQL
Goto Forum:
  


Current Time: Fri Apr 26 05:15:35 CDT 2024