<div class="content" name="MQSORTKEY" uuid="87995f3f-a493-4843-9f3f-c59c85fd93d6"><p>The MQSORTKEY structure specifies a sort key and sort order.
This structure is used in directory query operations to identify an <a href="993fa29f-3deb-494f-b4b4-492ee945735f#gt_0409899a-2e1c-452a-b5ae-5a524e2d9280" data-linktype="relative-path">MSMQ object property</a> to be
used as a sort key by which to sort the result set, and to define the sort
order for that key.</p><dl>
<dd>
<div><pre> typedef struct tagMQSORTKEY {
   unsigned long propColumn;
   unsigned long dwOrder;
 } MQSORTKEY;
</pre></div>
</dd></dl><p><b>propColumn:</b>   The <a href="993fa29f-3deb-494f-b4b4-492ee945735f#gt_382ac1cd-8ff9-493a-bfec-d9ad08955707" data-linktype="relative-path">property identifier</a> to be
used as the sort key. MUST be one of the values specified in the object
property identifier table in section <a href="1f12668a-2fa3-45cf-8236-74f0fe4a6b7d" data-linktype="relative-path">2.2.10.1</a>. </p><p><b>dwOrder:</b>   A symbolic constant specifying
whether the sort is to be done in ascending or descending order. MUST be set to
one of the following values.</p><table><thead>
  <tr>
   <th>
   <p>Value</p>
   </th>
   <th>
   <p>Meaning</p>
   </th>
  </tr>
 </thead><tbody><tr>
  <td>QUERY_SORTASCEND 0x00000000</td>
  <td>Ascending sort.</td>
 </tr><tr>
  <td>QUERY_SORTDESCEND 0x00000001</td>
  <td>Descending sort.</td>
 </tr></tbody></table><p> </p></div>