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

Home -> Community -> Usenet -> c.d.o.server -> Re: NEWBIE ?: SQL command not properly ended

Re: NEWBIE ?: SQL command not properly ended

From: DA Morgan <damorgan_at_exesolutions.com>
Date: Mon, 27 Jan 2003 20:10:02 -0800
Message-ID: <3E360299.7EDB908@exesolutions.com>


Steve wrote:

> I just installed Oracle 9i Personal edition on my Windows XP Pro
> laptop and am having a difficult time getting going. Just to test out
> some queries I tried running a extremely simple SQL statement against
> the database:
>
> SELECT * FROM EMX.HR.DEPARTMENT;
>
> When executing the query I get ERROR at line 1: ORA-00933: SQL command
> not properly ended. Someone help, I'm getting depressed that I can't
> execute the simplest of queries!!!

The query may be simple but your syntaqx has nothing to do with Oracle. If you want to work with Oracle the first thing you need to understand is that all RDBMS products are different and you must learn to do Oracle the way Oracle does Oracle.

If you are in the schema that owns the DEPARTMENT table you only need:

SELECT * FROM department;

If DEPARTMENT is owned by another schema, assuming you have SELECT privilege access to that table:

SELECT * FROM schema_name.department;

Two periods is just not Oracle.

To find out who owns the table try:

SELECT owner FROM all_tables WHERE table_name = 'DEPARTMENT';

Daniel Morgan Received on Mon Jan 27 2003 - 22:10:02 CST

Original text of this message

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