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 -> Re: Difference between "SELECT *" and "SELECT COLUMN1, ..., COLUMNN"

Re: Difference between "SELECT *" and "SELECT COLUMN1, ..., COLUMNN"

From: Brian Ross <brian.ross_at_home.com>
Date: Wed, 29 Aug 2001 11:35:58 -0500
Message-ID: <fZ7j7.17842$Z2.228109@nnrp1.uunet.ca>


> > I am having a problem where if I execute a query using "SELECT
> > *" I don't have any records returned even though I know there
> > should be. If I change it to "SELECT COLUMN1, etc" the record
> > is returned successfuly. There are no errors or warnings
> > returned in the first case. What could be causing the first
> > select to fail?
>
> Are you using some programming language for this and can't
> retrieve from a cursor, or is this happening in SQLPlus?
>
> If former, can you check if the query runs correctly in SQLPlus
> first?

It is from a programming language (ADO/C++). The query runs OK when I run from an external query program.

It seems that this has something to do with a column being the 'LONG' datatype and the order of the columns that are selected. If I move the name for the LONG column to the end of the SELECT list I can now retrieve my recordset. If there are any columns selected after the long column then my recordset won't have any records.

I am beginning to think this may be more of an ADO/ODBC issue but it would be great if anyone has any suggestions as to what might be the proper solution? Received on Wed Aug 29 2001 - 11:35:58 CDT

Original text of this message

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