Sort sequence (QSRTSEQ) system value

The sort sequence (QSRTSEQ), along with QLANGID, is used to determine the sort sequence table to be used for sorting character data.

You can change QSRTSEQ to any one of the following values:

Value Meaning
*HEX No sort sequence table is used. The hexadecimal values of the graphic characters are used to determine the sort sequence (a binary sort). This is the only sort sequence available for DBCS data.
Note: When you specify values other than *HEX for mixed-byte character data, SBCS character data is sorted according to the sort sequence specified. DBCS character data is sorted by hexadecimal values (binary sort).
*LANGIDSHR The sort sequence table can use the same weight for multiple graphic characters. The shared-weight sort table associated with the language specified in the LANGID parameter is used. This sort applies only to SBCS data.
*LANGIDUNQ The sort sequence table contains uniquely weighted graphic characters. The unique-weight sort table associated with the language specified in the LANGID parameter is used. This sort applies only to SBCS data.
Qualified sort sequence table name The name and library of the sort sequence table to be used. This value allows you to specify a sort sequence table other than those associated with the language specified in the LANGID parameter. This sort sequence table can be used to sort Unicode and SBCS data.
Related concepts
Language identifier (QLANGID) system value
Sort sequence tables
Database file attributes
Job attributes
ILE RPG sort sequence
DB2 and SQL sort sequence
iSeries Access sort sequence
Sort sequence support in work management