Problem with emails with "Invalid or non existent document"

When this error occurs "Invalid or non existent document" with  a notes client's email. The email cannot be deleted unless by doing a Shift/F9 (repair of the index) this will get rid of the email. Is there a way to restore the email without needing to restore from a tape backup or having the sender re-send the email? I would like to avoid even doing a SHIFT/F9 to get any email fixed.
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

That error usually occurs with an out of date or corruptindex (which shift-f9 usually fixes permanently).  The document, in all cases, was already deleted, it was just still showing in the view.  The document could have been deleted automatically if it was corrupt (fixup will do this -- it actually purges the document without leaving a deletion stub, which is what normal deletion would leave). Or, the user could have simply deleted the document, though this usually results in Document has been deleted, not in Invalid or nonexistent document.

If this error occirs repeatedly, I have two suggestions:
1) hunt down what is causing the document to get deleted in teh first place, check your logs
2) if shift-f9 fixes the problem but t returns for the same view, doa complete replace design of the user mailbox, because it sounds as if the design source has become corrupted

It also can't hurt to do a full compact/fixup/reindex

FYI, this really elongs in the Lotus DOmino Administration topic area.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
twizted_teckAuthor Commented:
So after the email has become corrupt, it is impossible to fix the email other than to restore from tape media or having the email re-sent?
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

The email has not become corrupt, only the view index.  However, it is possible that a "deeper" case is that some of the messages became corrupt and were purged (since a corrupt document is not permitted).  Docs unexpectdly purged might cause the index to fail to update (so it leaves an entry for the purged doc, with no actual document behind it).  View rebuild causes complete initialization of view index, so only valid docs are added back in.

Does that clarify?

If you did lose a corrupt doc, thn yes, the only way to get it back is from a separate copy (which could be tape, or could be a replicated/clustered mail file copy).
twizted_teckAuthor Commented:
Thanks for your help qualetee!!!
I am using C to render the note. I am stucked when I come to the point CompoundTextAddRenderedNote(params..........)
It is giving ERROR code 551->"Invalid or nonexistent document".
How to get rid of from this issue...? Please help me.

Below is the attaced NSF.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Lotus IBM

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.