Memcache is a cache key, which, as you described, is usually used when you know exactly what data you want to receive (i.e., it is not used to query and return an unknown list of results based on some filters).
Typically, the goal is not to replace all database queries with memcache calls, especially if optimization is not required.
Assuming the data will not match a single value, and you need quick access to all the data in your table, you might consider dumping them to keys based on some chunk value, such as the timestamp range.
However, it is probably best to either save the database query or load it directly into memory (if we are talking about a single server that writes all updates).
source share