Thursday, January 09, 2014

ORA-02494

This was tested on Oracle 11.2. If you create a tablespace with a datafile with autoextend on, the file’s maxsize cannot be less than its size. If it is, you get an ORA-02494: 

SQL> l
  1  create tablespace andrew
  2  datafile '/tmp/andrew.dbf'
  3* size 200m autoextend on maxsize 100m
SQL> /
size 200m autoextend on maxsize 100m
                                   *
ERROR at line 3:
ORA-02494: invalid or missing maximum file size in
MAXSIZE clause
 
SQL> l
  1  create tablespace andrew
  2  datafile '/tmp/andrew.dbf'
  3* size 200m autoextend on maxsize 300m
SQL> /
 
Tablespace created.
 
SQL>

No comments: