copying docs while retaining unique doc id

90 pts.
Database replication
I am having to restore data (alot of it!). I am doing this in stages due to the volume of data I'm dealing with. I'd like to copy the docs from the backup copy (made via replica) to the production database while retaining the unique document id. I know I've seen code for this, and relatively recently, but now that I need it, I cannot find it. Can anyone help me?

Answer Wiki

Thanks. We'll let you know when a new response is added.

Assuming that you are restoring the data because it was deleted unintentionally I would remove the deletion stubs and then push data from the backup replica into the production replica. Below is a link to a technote on how to remove deletion stubs from IBM support.

Discuss This Question: 1  Reply

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • tjarman
    Here is what happened... The deletion was unintentional, but not done by a user. A few people were in the database performing various activities. One being a very intensive processing function that does alot of comparing between documents to weed out duplicate entries and note various differences between them. This was involving probably close to 30-40k documents at the time of the last data loss. This happened twice. The first time we did a complete db restore since we lost all but 600 records and they jumped in and started work again. Then it happened again but we lost maybe 200,000 records instead of 700,000. There were no error messages the first time. It was discovered when they asked me a question and I went in to answer it, only to find all the data missing. The second time it happened, received messages. One was "Server error: Insufficient memory". The second message was something that started with "Database corrupt". The latter message seemed to resolve itself as I didn't do anything to gain access back to the database. Server support may have done something. Who knows. But the net result was massive data loss. I've been able to identify the differences between the various backup copies by using the unique id of the documents. I'm collecting them and copying them to the production database. I would rather retain the unique id of the document though. I'm doing this with scripts - no way I can do this manually! I'm not sure that the removing the deletion stubs would buy me anything as I don't know much about them. And since the docs were not marked for deletion by a user (or script for that matter), I don't know that they are still out there. So that raises another question - would removing the deletion stubs work for me? I think the database does not do soft deletions. I'd check, but I just lost my connectivity to my work's network. Any thoughts?
    90 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.


Share this item with your network: