Skip to content
Advertisement

Why do I get an Error when I try to rename a table after FROM?

When I simply try to retrieve all of the rows in my table EMPLOYEE like this:

I get the following error:

If I remove the AS emp it works just perfectly fine, but I want to rename my table here. Am I missing something totally obvious?

Advertisement

Answer

I believe that is a problem with your database engine. From the error i gather you are using Oracle. Oracle alias for tables is: table_name alias_name (https://www.techonthenet.com/oracle/alias.php)

So change the query to:

User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement