OE stores messages in database files (DBX files) with one DBX per folder in OE.For example, all the messages in the folder Inbox are contained in a single Inbox.dbx file, located in the OE Message Store folder.
When you move or delete messages, they are still in the DBX file but are tagged for later removal.
That's what the compacting process does, cleans up the accumulated junk in the DBX file.
The longer you put off compacting, the more junk has accumulated, and the higher the chance of the file corrupting when it finally is allowed to compact. That's what's happened to you.
If things worked as they should, OE has sent back-ups to the Recycle bin with an extension of BAK as part of the compact process (eg: Inbox.bak). If the back-ups aren't corrupted, you can place them in a new folder on the desktop, change the extension from BAK to DBX and run the OE Import tool to get the messages back into OE. It's important to include the file Folders.bak, changing it to Folders.dbx for the Import to succeed.