don't add limit 0 to query if no limit specified