Use offline backup to restore Data in DB2.
First, the data in the simulated table is damaged. --- Delete the data or clear the table.
DB2 => connect to mydb
Database connection information
Database Server = DB2/nt64 9.7.4
SQL authorization id = db2admin
Local Database alias = mydb
DB2 => select * from test
ID
----------
1
1 record selected.
DB2 => drop Table Test
The db20000i SQL command is successfully completed.
DB2 => select * from test
Sql0204n "db2admin. Test" is an undefined name. Sqlstate = 42704
Restore the table and its data.
DB2 => Restore database mydatabase fromd: \ backup taken at 20110925085106
Sql2539w warning! Restoring to the same existing database as the backup image database. The database file will be deleted.
Do you want to continue? (Y/n) y
The db20000i Restore database command is successfully completed.
DB2 => select * from test
Sql1024n does not have a database connection. Sqlstate = 08003
DB2 => connect to mydb
Database connection information
Database Server = DB2/nt64 9.7.4
SQL authorization id = db2admin
Local Database alias = mydb
DB2 => select * from test
ID
----------
1
1 record selected.
Recovery successful.