Link to home
Start Free TrialLog in
Avatar of Star79
Star79Flag for United States of America

asked on

Create table from select - oracle

Hello,
I ran the below query :
CREATE TABLE test
  AS (SELECT * FROM FACT_SALES);
iam trying to create the test the same as the fact_sales.But I get an error:

SQL Error: ORA-00911: invalid character
00911. 00000 -  "invalid character"
*Cause:    identifiers may not start with any ASCII character other than
           letters and numbers.  $#_ are also allowed after the first
           character.  Identifiers enclosed by doublequotes may contain
           any character other than a doublequote.  Alternative quotes
           (q'#...#') cannot use spaces, tabs, or carriage returns as
           delimiters.


Please help, so that my test table will have the same structure as the factsales and also the data
Avatar of johnsone
johnsone
Flag of United States of America image

Can you do a DESCRIBE on the table?  My guess is you have an oddly named column that is going to require double quotes around the name.
ASKER CERTIFIED SOLUTION
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Star79

ASKER

Please close the question as it was an issue with the sql query editor.The query works
Avatar of slightwv (䄆 Netminder)
slightwv (䄆 Netminder)

You can request to delete the question.  However, if the issue was with the tool and the syntax was correct as posted, didn't my post pretty much tell you that?
Avatar of Star79

ASKER

Please delete the question
You can delete the question.