Skip to main content
Mitratech Success Center

Transformations

Caution: This feature is for advanced DataStore®DSX users.

Index Field Transformation is provided to enable you to manipulate data that might not pass validation. For example, consider you have a document in which the date is stored as 05072005. This, in its current state, is not a valid date. It needs to be transformed so it’s displayed as 05/07/2005.

Note: Transformations can be applied to Content fields only. That is, Transformations are not available for manually entered field values.

  1. On the Validation tab, click the New Format button to create a new transformation definition.
    image
     
  2. Enter a Regular Expression mask to define how the string should be split in to components. In the above date example, the date in the file is stored as 05072005 where 05 is the day, 07 is the month and 2005 is the year. Therefore, the Mask to match index field is (\d{2})(\d{2})(\d{4}).
  3. Next, enter the order of the components and any separators you want to use. In this example, enter {0}/{1}/{2} in the text box Format to transform value
    (However, to change the date to the USA format of month/day/year, enter the Format to transform value {1}/{0}/{2}.)
  4. Before you can save the transformation definition, you must enter a String to be tested. Enter 05072005 and click the Test Custom Format button. When the transformation is successful, you are shown a Successful Transformation window. Check the date has been transformed correctly and click OK to close the window. Click OK on the Custom Format Editor window to save the transformation definition (or Cancel to exit without saving). The new transformation is now displayed in the Index Field Value Transformation list.

This transformation is applied to the string (extracted from the document) before the validation is applied.

  • Was this article helpful?