fix sqlite init code

Hey there, two issues with your sqlite initialization code

- multi-line statements don't seem to work with sqlite, the `create index` statement is never run
- and that's why the syntax error in that statement goes unnoticed, it should be `CREATE UNIQUE INDEX <<IDXNAME>> ON messages(id);`