Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Row count from REF CURSOR

Row count from REF CURSOR

From: <greg.sewell_at_gmail.com>
Date: 15 Feb 2006 06:02:59 -0800
Message-ID: <1140012179.431100.175920@g44g2000cwa.googlegroups.com>


I'm sure I'm just missing something, but can't seem to find the answer.

We have a function that returns a REF CURSOR using the OPEN..FOR syntax. The SQL for the cursor is dynamically built in the procedure based on a series of configurations, such that the cursor will always be different based on the most current configuration. The generalized approach is that the dynamic SQL string is stored in a temporary table and then retrieved.

	SELECT to_char(SQLTranslationString)
	INTO vcSQLTranslationString
	FROM TranslationString
	WHERE AuditID = iAuditID;

	OPEN returnCursor FOR vcSQLTranslationString;

In this particular system, we have stringent audit requirements, such that we have to know the final target row count. I know the calling system that initiated the procedure can always call back and tell me the answer, but I was wondering if I could force the procedure to do it. I tried the following:

        iRowsProcessed := returnCursor%ROWCOUNT; , but found in the documentation that this will always be zero.

Any suggestions? Received on Wed Feb 15 2006 - 08:02:59 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US