Support > Repository > Check the input > Regular expression check

You can use regular expression expressions to specify a string pattern to be registered.

Figure 1 shows an example of specifying a rule (regular expressions) called "4 digits - 4 digits - 4 digits of numbers" in the telephone number field.

Figure 1 I did not match the regular expression rule for phone numbers

Because the input character contains characters, you can see that it is an error.

Figure 2 shows an example of setting the following regular expressions in the phone number field.


"D {1, 4}" means that one to four digits will be included."-?" Means that "-" may or may not be present.

Figure 2 Specifying a regular expression

Warning is displayed, but when you make setting that you do not disturb the registration itself by pressing the save button here, specify "warning" from the list box on the right side of the input field.(When it is blank, you can not register if an error occurs.)

Figure 3 Specifying warnings
Warning designation does not work on the list update screen (including parent child model simultaneous update screen).

Item of zip code type, The following formula is automatically applied.


However, if the developer explicitly specifies a regular expression, the expression is applied.

With Wagby's standard setting, you can not realize the rule "Can input only full-width characters". Allowable character type settingThen it will be specified as checking full-width Kanji or checking whether the space character (space) is half-width or full-width.

So set as follows.

  1. Input filter as "string (minimum)"will do.
  2. Specify the following regular expression.
  • This check is done in real time.(Check with JavaScript on browser.)
  • In the state of input error, you can not press the button such as "save".
  • The input item that caused an error has a background of red.This applies to text boxes or date/time list boxes.
  • If the regular expressions can not be interpreted (not working) by the browser's JavaScript, they will be processed on the server side (Java) after the save button is pressed.In other words, it is double check that the check process is applied even after the value of the form is transmitted.
  • When using in combination with "character count check", please devise a regular expression.[More ...]
  • It is not possible to check inputs for items that are not input targets.Specifically, it is an item which is obtained by calculation formulas, read-only item, reference linking item.

The repository key is model/modelitem/regexp.