deferred-query

Deferring frequent updates in MySQL

I have frequent updates to a user table that simply sets the last seen time of a user, and I was wondering whether there is a simple way to defer them and group them into a single query after a short timeout (5 minutes or so). This would reduce queries on my user database quite a lot. ...

Lambda expression to find difference

With the following data string[] data = { "a", "a", "b" }; I'd very much like to find duplicates and get this result: a I tried the following code var a = data.Distinct().ToList(); var b = a.Except(a).ToList(); obviously this didn't work, I can see what is happening above but I'm not sure how to fix it. ...