changed database from sql to postgresql