Reply
Thread Tools
Posts: 9 | Thanked: 1 time | Joined on Aug 2007
#1
One night I turned off completely the tablet on low battery while maemopad+ was still open. Next day all my notes were gone. The memos.db file was still to be found in the filemanager, but with a size of 11k instead of 3mb. Where did the rest of the database go? Is there any hope of recovering it from somewhere? Don't have a recent backup . OS2007.

--jose
 
Posts: 1 | Thanked: 2 times | Joined on Apr 2008
#2
I also had battery run out with maemopad+ open. memos.db was still there but maemopad+ opened to a blank screen. sqlite3 v 3.2.8-1 on Ubuntu reported memos.db file was "unsupported file format" as did pysqlite2 on same machine, but sqlite3 from sqlite3-tools-3.4.2-1 on Mandriva machine opened the db.

In sqlite3 did
sqlite> .output outfile.sql
sqlite> .dump
sqlite> .quit

Examining outfile.sql in Emacs I found that tables for nodes, checklists and nodesbackup were created but there were no insert statements for the nodes table.
Copied all insert statements for nodesbackup and changed all the copied 'INSERT INTO "nodesbackup".... ' to 'INSERT INTO "nodes".... '.

The sql file started with delete and insert statements for a table "sqlite_sequence". Move those lines to after the first CREATE TABLE statement. Sqlite creates the sqlite_sequence table automatically after a table is made with autoincrement. To generate a new database a create table with autoincrement has to happen first so the sqlite_sequence table exists when the delete and insert statements for it are run.

Saved the sql file and started sqlite3 with "sqlite3 memo_rebuild.db", then did
sqlite> .read outfile.sql
sqlite> .quit

Copied the memo_rebuild.db to the N800 and opened it with maemopad+ and all my data is back!

Thanks to disq for having that nodesbackup table!

IanS
 

The Following 2 Users Say Thank You to ian800 For This Useful Post:
Posts: 9 | Thanked: 1 time | Joined on Aug 2007
#3
thanks for your detailed reply - unfortunately by now I have already upgraded to os2008 and I imagine with the upgrade both nodes and nodesbackup should be gone (?). Meanwhile I have moved on to Quicknote though I still miss some of the entries lost at that maemopad+ crash
 
Reply

Thread Tools

 
Forum Jump


All times are GMT. The time now is 07:02.