Rewrote database support to classes, added SQLite3 (might still be buggy due to unsupported features)