storing session data in db