M204.1687

From m204wiki
Jump to navigation Jump to search

M204.1687  FNV on Ordered For loop was not an ORDERED field: field ​=​ fieldName

A field name variable (%%fieldname) was executed in a For Each Record In Order By %%fieldname statement, and the %fieldname contains the name of a NONORDERED field. The In Order By clause cannot be used with NONORDERED fields.

Response: The Sort Records statement must be used to order records by a NONORDERED non-SORT KEY field. Correct the program to use the Sort statement if ordering by a NONORDERED field is required.

File manager response: Consider making the field ORDERED, since For Each Record In Order By may be more efficient than the Sort Records statement.

Message attributes:

RETCODEO=0Sets online return code
RETCODEB=4Sets batch (single user) return code
CLASS=EError class; the message can be suppressed with the X'04' bit setting of the MSGCTL parameter
AUDITERWrites the message with line type ER to the audit trail
CANCELCancels the user's request
COUNTIncrements the error count (ERCNT) parameter

Back to list of messages