问题描述:

I'm trying to understand how SqlCacheDependency works in a bulk update situation.

I understand how to set it up and if I make one row change in the database my cache becomes invalid.

My question is if I do a bulk update on a table that has 100 rows

UPDATE MyTable

SET Col = 1

Question

Do I get 100 invalidate notifications, or is it smart enough to know the data changed and only 1 notification is sent, thus it only invalidates the data once?

I'm using something similar to this:Example

My concern is that if it invalidates over and over again then it will be hitting the database 100 times to get the fresh data and I would have to think of an alternative strategy.

Regards DotnetShadow

相关阅读:
Top