Want to group by date? Cast to date!

When extracting timed statistics from SQL you usually want these stats grouped by some kind of time and more often than not this time unit is days. I used to do this unnecessarily complicated by converting the dates to varchars in formats I didn’t even want and...

Yield Return Dangerously Delicious

I´m a big fan of neat constructs such as the yield return in C#. The yield return allows you to return results from a method line by line instead of summing it up in a list or such. You can see the difference between these two methods: public IEnumerable<string>...

Comparing exact datetimes in entity framework

Seems there´s still some issues you have to struggle with in Entity Framework even though the latest releases have made it actually possible to work with. This time I got a problem whilst trying to retreive av bunch of items logged with the same timestamp. Entity...