Changed database queries.