modified dml query to retrive only selected fields