support also mode in search sorting, and fail on illegal parameters