Skip to content

Latest commit

 

History

History
30 lines (25 loc) · 1.41 KB

fact-mapping-options-array-conditions.rst

File metadata and controls

30 lines (25 loc) · 1.41 KB

Allows you to sort an embedded array and limit the amount of entries in that array. You can apply only a sort, only a limit, or both. When limiting to a single entry, there is the option to embed as a document instead of a single-element array by selecting the :guilabel:`Create an array of primitive values` :icon-fa5:`check-square`.

  1. On the :guilabel:`Mappings` pane, click the :icon-fa5:`chevron-left` icon next to :guilabel:`Advanced settings`.
  2. Select the :guilabel:`Add array conditions` :icon-fa5:`check-square` icon.
  3. Enter a filter in the :guilabel:`Value expression` text box.
  4. In the :guilabel:`Sort by and order` heading, select the source field to sort on and toggle between :icon-lg:`SortAscending` for ascending and :icon-lg:`SortDescending` for descending order.
  5. Select a :guilabel:`Limit` option:

Note

  • Excluded fields cannot be sorted on. If a previously selected sorting field is excluded at a later point in time, the array condition is removed.
  • If an array is modified during the CDC stage of a continuous job, sorting and limiting considers only the newly modified row and the pre-existing array elements, not the other values from the table which are not in the array.