Support > Repository > Check the input > Range check
ja | en

You can specify the range that can be entered for numeric type and date type.

Figure 1 shows an example in which the range of "age" is set from 0 to 130.Values ​​outside the range will result in an error.

Figure 1 Age range check
Numerical range checking is done in real time.

Input check - fill in the value in the range check.

Figure 2 Specifying the numerical range

A positive number

Specify the range by concatenating two numbers with "-" (hyphen).
For example, if you want to restrict input to only numeric values ​​from 1 to 10, specify "1-10" for this item.

Negative number

If you want to include negative numbers, enclose them in parentheses "()".
For example, if you want input from -10 to 10, specify "(- 10) - 10".

Use as character count check

For example, in case of 4 digits, specify "0-9999".

You can specify "valid date until yyyy year MM month dd day".

Figure 4 shows an example in which "2000/1/1-" is described in the range.Entering the previous value will result in an error.

Fig.3 Dialing exceeded the date range setting was made
Date range checking is not done in real time.After the save button is pressed, it is checked on the server side.

Fixed date is specified in yyyy/MM/dd format. An expression including "now" can also be described.Now is a special notation meaning "the day".

Description exampleDescription
(now-7)-(now-1) From 7 days ago to 1 day before
(now-7)-now 7 days ago to today
(now-7)-2013/1/1 7 days ago to 1 January 2013
now-2013/12/31 From today to December 31, 2013
2013/1/1-now From 1 January 2013 until today
2013/1/1-(now+7) From 1 January 2013 until 7 days from today
-now until today
now- Since today
now Today only
now,now+2 Today and the day after tomorrow
now,now+2,now+4 Today and the day after tomorrow, after 4 days
2013/1/1,now,2013/12/31 January 1, 2013, today, and December 31, 2013

Note that you can not write an expression that is a mixture of commas and hyphens.The following notation is incorrect.

 (now-7)-(now-5),(now-3),(now+2)-(now+5)

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 4 is an example of a numeric type, but the date type is similar.

Figure 4 Specifying warnings
Warning designation does not work on the list update screen (including parent child model simultaneous update screen).
  • 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.

The repository key is model/modelitem/range.