table locking for select statements