0

I have sybase database with 500 GB of space.It has 50 datadevices of 10GB each.

The problem is due to large number of data,DB got full so we have cleaned up the database,but still the row file of database has not cleared.

All tables are empty so why raw file hasn't cleared yet.

c:/sybase/abcdata 499GB 500GB

Thanks in Advance

Mike Gardner
  • 6,611
  • 5
  • 24
  • 34

1 Answers1

0

Sybase ASE device files are not like regular files. Once they grow, they will not shrink back down. This does not mean the database is full, only that the devices have been fully allocated to the database. The size of the disk files does not indicate how 'full' a database is.

sp_spaceused will give you the information about how much of the alloted space your database is using. If you find that even after you delete a bunch of data, your usage does not go down much, you may need to look into the reorg commands like reorg rebuild or reorg reclaim_space.

To physically shrink your database you will have to do a BCP out, drop your database, and rebuild it with less disk space.

On a side note, Sybase no longer recommends the use of raw files for Windows devices in ASE, but it may depend on what version you are running.

Mike Gardner
  • 6,611
  • 5
  • 24
  • 34