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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Invalid column in table - how to access it?

RE: Invalid column in table - how to access it?

From: Jacques Kilchoer <Jacques.Kilchoer_at_quest.com>
Date: Fri, 28 Feb 2003 11:16:18 -0800
Message-ID: <F001.0055D482.20030228111618@fatcity.com>


> -----Original Message-----
> From: maheswara.rao_at_sungard.com [mailto:maheswara.rao_at_sungard.com]
>
> I have a table - messages. I couldn't access one column in this table
> when I do
>
> Select name from messages;
>
> I get an error message - ORA-00904: invalid column name
>
> All the other columns I could select from this table. When I checked
> the table structure through OEM, I found this column has double quotes
> around it i.e., "NAME". All other columns do not have double quotes
> around their name.
>
> Question:
>
> How do I select this column from select statement?
>
> How do I correct this problem?

That's funny. "name" is not an Oracle Reserved Word (see Appendix C of the SQL reference manual) as far as I know. I was able to create a table called NAME with a column called NAME and do a select without the double quotes.

What would the output of
select column_name, dump (column_name)
from user_tab_columns
where table_name = 'THE_TABLE_NAME' ;
show?

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Jacques Kilchoer
  INET: Jacques.Kilchoer_at_quest.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Fri Feb 28 2003 - 13:16:18 CST

Original text of this message

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