How to limit the digit in number data type field

A

anomynous

Hi,

In the General tab of the table set Fiels Size to 8, and
Format to 00000000 (8 zeroes). This should do the trick, I
guess.
 
A

Anonymous

Oops, sorry, I think only the format is enough. Field Size
can just be Long Integer.
 
T

Tim Ferguson

Oops, sorry, I think only the format is enough. Field Size
can just be Long Integer.

No: format only affects the displayed text, so setting it to "00000000"
will just pad the front with zeroes.

If it has to be a number, then it has to be a validation rule like

Is Null Or (>9999999 And <100000000)

BTW that is seven nines and eight zeroes...

If it is a text field (which may well be more appropriate) then setting the
field Size to 8 will provide a maximum, but the OP will still need to
prevent short entries with something like

Is Null Or Len(MyField)=8

Hope that helps


Tim F
 

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