regex validate field; allowed is empty, null or one word max 30 ch

G

Guest

Hi all,

I have got the following problem:
User fills in excel sheet, this is loaded in Acces.
After this I run a validation tool to validate the field formats.

One fields is allowed to be null, empty (length = 0) and max 30 chars.
I use the following expression: ^.{0,30}\b

It seems that this is not working as I would expect when fields are empty or
""...

Any ideas...?

Cheers
 
G

Guest

Ludovic,

There are also other fields that needs to be validated.
All validation rules are stored in a table as well.
I decided to do all validations the same way: using regex...

I know your solution, checking the length, is also possible.
But it shouldn't be that hard to define this using regex....
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top