swapping sqllite for postgres