title: How to recover data from a corrupt SQLite3 database?
body: <p>I've recovered data from a formatted hard drive for use in a lawsuit. The data is Skype logs, which are stored in SQLite3 databases. Unfortunately, the disk was formatted and a new copy of OS X was installed on the drive. I scanned the drive and found the files I am looking for, but it seems that the database I'm after is corrupt.</p>
  
  <p>I tried the following command I found by searching on SO:</p>
  
  <pre><code>$ sqlite3 mydata.db ".dump" | sqlite3 new.db
  </code></pre>
  
  <p>Unfortunately, dumping this way excludes the table of records I'm looking for (Messages). Since I can get the format of the DB from Skype by just logging in with another account and generating a new main.db for it, do I have any additional options for extracting the contents of the corrupt DB? Failing that, is there a way to export the raw contents of the database in a text file or something? I only care about grabbing certain messages, which I can search for.</p>