Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Starting with SWAT 20.05 version, you can use regular expressions definitions to specify the format of a character field. The definition is added in the 'extendedFormat' attribute in the designer.

We support static masks, dynamic masks and Regex expressions.the following masks:

  • static masks (ex: 99-9999999 or (999) 999-9999)
  • dynamic masks (ex: aa-9{1,4} - the 9 digit can occur 1 to 4 times)
  • Regex expressions (ex: [0-9]*)

Masking definitions:

  • 9 - numeric
  • a - alphabetical
  • * - alphanumeric

Exampled Examples for the extendedFormat attribute on character fields to specify the format:

  • extendedFormat: aa-9999
  • extendedFormat: aa-9 {4}
  • extendedFormat: regex:[0-9]*

Where to use it?

  • specifying a field used to enter a credit card number (9999-9999-9999-9999) or a person`s ID number (9999.9999.99) with a specific format