The following error message is output when ALTER TABLESPACE ... DROP DATAFILE is executed:
The following error description can be viewed with the AltiErr utility:
Even if the user executed an INSERT statement and followed it with a DELETE statement so that all the datafiles can only have free pages, a previously used datafile cannot be dropped.
This error occurs when an attempt is made to drop a datafile that has previously been used.
Only datafiles that have never been used can be dropped.
It is impossible to drop a datafile that was used even once.
To drop a datafile, the tablespace must be recreated as below: