Home » SQL & PL/SQL » SQL & PL/SQL » ORA-00942 Error
ORA-00942 Error [message #277376] Mon, 29 October 2007 17:02 Go to next message
brig
Messages: 14
Registered: July 2007
Junior Member
Hi

I was wondering if anyone could help with this. I understand the error is "table or view does not exist". I ran a script to see if the table or view exists and it does.

History: I used ODBC to bring this table over from access. Which is successful in all accounts except I can not do anything with it.
I have tried as DBA, as a different user, I have exported and imported it as a different user. I have given rights. I am giving up Sad I read that that a user may need application rights. ??

Are they some special privileges or rights that I am missing?? I just keep adding rights to my test user as I don't know what else to do. But nothing is working.

Any suggestions??
Thank you for your time
brig
Re: ORA-00942 Error [message #277377 is a reply to message #277376] Mon, 29 October 2007 17:11 Go to previous messageGo to next message
BlackSwan
Messages: 25050
Registered: January 2009
Location: SoCal
Senior Member
http://www.orafaq.com/forum/t/88153/0/
It appears you have a problem & am getting ORA-00942 Error.
How ever, I have a problem too.
I have ZERO idea exactly what you are doing, so I can not even begin to guess to tell you how to do "it" correctly because I don't know what "it" actually is.

Frequently User_B gets the ORA_00942 error when trying to access TABLE_1 owned by a different user because of lack of permission or because did not fully qualify table_name.
SELECT * FROM USER_A.TABLE1

[Updated on: Mon, 29 October 2007 17:13] by Moderator

Report message to a moderator

Re: ORA-00942 Error [message #277378 is a reply to message #277376] Mon, 29 October 2007 17:15 Go to previous messageGo to next message
Kevin Meade
Messages: 2101
Registered: December 1999
Location: Connecticut USA
Senior Member
maybe upper lower case issue.

select table_name
from user_tables
order by table_name
/

The table may have been created with a name using one or more lower caes letters. Oracle by default does not do that.

18:10:51 SQL> set linesize 70
18:11:01 SQL> create table temp1 (a number);

Table created.

Elapsed: 00:00:00.01
18:11:02 SQL> desc temp1
 Name                                Null?    Type
 ----------------------------------- -------- ------------------------
 A                                            NUMBER

18:11:02 SQL> 
18:11:07 SQL> 
18:11:07 SQL> create table "temp2" (a number);

Table created.

Elapsed: 00:00:00.01
18:11:08 SQL> desc temp2
ERROR:
ORA-04043: object temp2 does not exist


18:11:08 SQL> desc "temp2"
 Name                                Null?    Type
 ----------------------------------- -------- ------------------------
 A                                            NUMBER

18:11:15 SQL> 


since the table got created with lowercase letters, we are now forced to refer to it always using quoted name sytnax.

18:11:15 SQL> select table_name
18:12:08   2  from user_tables
18:12:09   3  where upper(table_Name) like 'TEMP%'
18:12:16   4  /

TABLE_NAME
------------------------------
TEMP1
temp2

Elapsed: 00:00:00.01


Notice the error I got is ora-04043, not ora-00942. Something only different.

good luck, Kevin
Re: ORA-00942 Error [message #277428 is a reply to message #277378] Tue, 30 October 2007 01:38 Go to previous messageGo to next message
Michel Cadot
Messages: 64152
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:

Notice the error I got is ora-04043, not ora-00942. Something only different.

The difference is you use DESC and not SELECT.
The return code comes from the way DESC is coded in SQL*Plus.

Regards
Michel
Re: ORA-00942 Error [message #277511 is a reply to message #277376] Tue, 30 October 2007 07:07 Go to previous messageGo to next message
brig
Messages: 14
Registered: July 2007
Junior Member
Kevin...


THANK YOU!!! That was it.
I had to rename my tables in access to lowercase and all worked fine.
I can not thank you enough. Smile
I don't even need the parens.......

brig
Re: ORA-00942 Error [message #277535 is a reply to message #277511] Tue, 30 October 2007 08:19 Go to previous messageGo to next message
Kevin Meade
Messages: 2101
Registered: December 1999
Location: Connecticut USA
Senior Member
you are welcome. An easy mistake to make. I know, did it myself several times.

Good luck, Kevin Meade

to Michel,... that is a neat piece of trivia, thanks. Let me ask you, where did you learn that one?
Re: ORA-00942 Error [message #277536 is a reply to message #277535] Tue, 30 October 2007 08:24 Go to previous message
Michel Cadot
Messages: 64152
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:

where did you learn that one?

Dump SQL*Plus net frames, but sh!

Regards
Michel
Previous Topic: Generate trigger statement using store procedure
Next Topic: Remote Pipeline
Goto Forum:
  


Current Time: Sat Dec 10 04:51:46 CST 2016

Total time taken to generate the page: 0.08629 seconds