I'm not entirely clear on what you're asking for.
Are you trying to limit the number of records in a table in the database?
If so, then I'd probably create a trigger on the database. The way to do that would be dependent on which database you are using.
If not, can you explain a little more?
-Jim