0

I am trying to create a new temporary tablespace for testing purposes (the code to be tested is actually designed to work with an external Oracle database, all the important tables sharing the same tablespace named `sbrdwh').

To test the code, I have to create my own db with the same schema and the same tablespace, but when it comes to the latter, ORA-02180 is thrown.

My command looks like this:

CREATE TEMPORARY TABLESPACE sbrdwh FILE '/tmp/sbrdwh.dbf' SIZE 10M;

What am I doing wrongly?

The user who issues this command has privileges to create tablespaces and unlimited tablespace quota.

CREATE TEMPORARY TABLESPACE sbrdwh TEMPFILE '/tmp/sbrdwh.dbf' SIZE 10M;

didn't work also.

distort86
  • 43
  • 4
  • Do you have proper security access? If your syntax is correct but you are receiving errors then the first thing to check is your security privileges. –  Sep 09 '14 at 13:58
  • @DanK Thank you, I have already checked it -- more than that, I have granted unlimited tablespace privilege to the user. – distort86 Sep 09 '14 at 16:31

1 Answers1

2

I think the correct keyword is DATAFILE or TEMPFILE, not FILE:

CREATE TEMPORARY TABLESPACE sbrdwh TEMPFILE '/tmp/sbrdwh.dbf' SIZE 10M;
Gordon Linoff
  • 1,242,037
  • 58
  • 646
  • 786