Regular expression checks

We’ve just added a useful new feature – regular expressions.

In other words, rather than just using simple rules to limit the ability for people to enter duff data, such as ’email addresses must contain an @ sign’, an administrator can now in addition add arbitrarily complex checks, as long as they know how to write regular expressions.

They can also be used to create advanced filters in views.

This might be something that people who’ve done a little programming might be excited by, but it perhaps others may also like to expand their skillsets with a bit of learning.

regular_expressions
xkcd.com

For full documentation, please see

https://www.postgresql.org/docs/current/static/functions-matching.html#FUNCTIONS-POSIX-REGEXP

To set up a data check in agileBase, go to a table in the admin interface, visit the ‘manage’ tab and click ‘checks’. Then from the dropdowns at the bottom of the screen, select a field and either ‘matches regular expression’ or ‘does not match regular expression’. Fill in the expression you’d like to check against to the right, e.g. [a-z] to match any data containing a letter of the alphabet.

regex checks

regex_golf_2x

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s