invalidates by comparing the values in key that are marked in the flags.
Either INVAL_PRIMARY or one of A,B,or NAME MUST be set
returns # of rows invalidated
this should be called occasionally via a scheduled event to purge the
cache of old and invalid entries. You could also schedule an event in the DB that
calls the SP that this method calls.
This should be called at least once a month, but weekly or daily may or
may not provide additional benefit. It depends on usage etc.