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

Home -> Community -> Usenet -> c.d.o.tools -> SQL-02112 SELECT ... INTO returns too many rows --- how to use the SELECT_ERROR option??

SQL-02112 SELECT ... INTO returns too many rows --- how to use the SELECT_ERROR option??

From: Dave Sutton <dpsutton_at_marchsystems.co.uk>
Date: Tue, 9 Jan 2001 17:10:02 -0000
Message-ID: <93fg6q$pfu$1@newsreaderg1.core.theplanet.net>

Hi,

Can anyone help me with this one?

I'm getting the following error when executing one of my stored procedures:

SQL-02112 SELECT ... INTO returns too many rows

I just require the first record that is returned by the select statement and wish to discard the rest.

The Oracle documentation suggests the following work-around:

Cause: A SELECT ... INTO statement returned more rows than can be stored in the host variable provided.

*****Use the precompiler option SELECT_ERROR=NO.******

However, I can't find any way of setting this option. I would prefer to set the option in-line within the stored procedure but will settle for anything I can get!

Hope you can help.

Thanks in advance.....

Dave Sutton Received on Tue Jan 09 2001 - 11:10:02 CST

Original text of this message

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