My Blog

Here you can find my private notes about programming that I wanted to share with you. Feel free to filter based on the topic you want or search for something specific.

    Use the HAVING keyword to count duplicates in rows of a SQL table

    There are times when you want to find out duplicated values in rows of a SQL table. We are going to use the HAVING keyword to list the values that are present more than one time. Let us consider the following table with three columns and three rows:

    Read the complete article

    Use the JsonConverter attribute to parse complex JSON object into a C# class

    I was working lately with some complex JSON objects coming from the alphavantage, an API for getting meta information about stocks, currencies and the world economy in general, and had to overcome major issues before being able to deserialize the strings into my C# POCO classes.

    Read the complete article

    Use the Fetch API to download files with their original filename and the proper way to catch server errors

    The Fetch API provides a handy way for downloading resources from the internet via JavaScript code. In my case I used it to download Excel sheets from the back-end of a web application. Let us check the code together and clarify things with the help of comments.

    Read the complete article

    Remove modified files from a Git Pull Request but keep them with their changes on your local branch

    The scenario described on the title of the article happens pretty often. You committed files, pushed them to a feature branch and created a new pull request to merge them to master. However, maybe you accidentally pushed modified files, for which work is still in progress and you do not want them on master yet. So now you want to remove specific files from the pull request but keep the changes you made in these files locally. How?

    Read the complete article

    The reason behind the "Cannot implicitly convert type System.Threading.Tasks.Task to XXX"

    A quick article this time about an error message in C# when dealing with asynchronous code calls.

    Read the complete article