How to restore one table from full backup in Sybase ASE

sybasesybase-ase-15.7

I need to retrieve 2 data records that were in a single table from yesterday's backup.

  • How can I restore a single table from a full backup in Sybase?
  • Or is it possible to retrieve the required records from the dump file itself?
  • Can I somehow load the dump file without recovering to the production database?

I don't have enough disk space to recover the database to a temporary database on the same disks/server.

Best Answer

Take a look at the ASE Archive Database feature.

This features allows you to mount your dump file(s) as a read-only database; once mounted you can access the tables in the database with your desired select queries.

Technically ...

  • you'll need to setup a smallish scratch database for managing the mount
  • it's possible to make non-persistent changes to data; this consists of allocating (optional) disk space to hold any modified pages (these changes will not be reflected in the database dump file(s)

For an example of setting up the scratch and archive databases, see the Reference manual entry for the create archive database command.