try to find problem writing to db