Restrict a Table number of Records

  • Thread starter Thread starter Bob Vance
  • Start date Start date
Is it possible to restrict a table to only 3 Records.....Thanks Bob

Make the primary key an integer (or byte) field with a validation rule of
greater than 0 and less than 4.
 
Thanks Rick , My Primary Key only has Long Integer! and Validation Rule wont
except >0 Or <4
Regards Bob
 
Thanks Rick , My Primary Key only has Long Integer!

Ummm... that can be changed. Or for that matter left alone (though using only
three out of four billion odd possible values is a bit wasteful)
and Validation Rule wont
except >0 Or <4

Syntax should be

[ID] > 0 AND [ID] < 4
 
Wasteful of storage is not much of a concern these days -- disk and main
memory are cheap. The long integer, normally, is aligned in memory so that
it likely performs better than a shorter variable/field would (at least in
the past); on the other hand, compute power is also cheap, these days, too.
So maybe it is just a tossup.

Larry Linson
Microsoft Office Access MVP


John W. Vinson said:
Thanks Rick , My Primary Key only has Long Integer!

Ummm... that can be changed. Or for that matter left alone (though using
only
three out of four billion odd possible values is a bit wasteful)
and Validation Rule wont
except >0 Or <4

Syntax should be

[ID] > 0 AND [ID] < 4
--

John W. Vinson [MVP]

__________ Information from ESET Smart Security, version of virus
signature database 4001 (20090411) __________

The message was checked by ESET Smart Security.

http://www.eset.com



__________ Information from ESET Smart Security, version of virus signature database 4001 (20090411) __________

The message was checked by ESET Smart Security.

http://www.eset.com
 
Back
Top