replaces sqlite3 with pg gem