DateTime – How to properly save and read date time in ASP.Net

There could be many ways of saving DateTime in an App. The simplest way is storing it as it is typed in by users if the website’s users are within a single country. If a website is serviced globally, confusion starts. Normally users might assume the date-time is local time. For example, if a user… Continue reading DateTime – How to properly save and read date time in ASP.Net

SQL query performance tuning

Tuning quick tips Getting the entire record before apply condition. -> Solution: Apply condition and paging before select. Using sub-query -> Solution: Turn it into join Using Table Variable being used with large data -> Solution: use Temp Table When a query performs badly, 3 things above are the most common causes I came across.… Continue reading SQL query performance tuning

SQL – Best way to get Total Count with pagination

Paginated query to SQL server is a very common logic that might be used literally everywhere. After googling a bit, the code below seems to be the best practice in 2020. The key point here is using Count(*) Over which allows getting list and total count at a single query. Select *, Count(*) Over ()… Continue reading SQL – Best way to get Total Count with pagination

C# Performance Improvement Experience

I have a personal code originally wriiten in 10 years ago when I was starting coding in University. The code is basically stock price analysis tool.  Recently I started to look at it again and found a few tips to improve the performance calculation and DB access heavy code. Actually, this shouldn’t be DB access… Continue reading C# Performance Improvement Experience

DDD Perth 2019

DDDPerth

DDD Perth 2019 looks get bigger than 2018. 835 developers joined and more than 200 were in waiting list. Food got better than last year. Multiple coffee post was another small improvement as there was a massive queue last year on a single coffee post. What I couldn’t understand is that there were 6 tracks… Continue reading DDD Perth 2019