Added assumption of attribute name only when 'by' parameter is not given