Legal Notice
The opinions expressed herein are my own personal opinions and do not represent my employer’s view in anyway.Top Posts
- C# HttpClient POST or PUT Json with content type application/json
- C# get results from Task.WhenAll
- C# Get expiry timestamp from JWT token
- Using C# HttpClient from Sync and Async code
- Run tasks in parallel using .NET Core, C# and async coding
- Handling "415 Unsupported Media Type" in .NET Core API
- c# Async fire and forget
Archive
Meta
Tag Archives: LINQ
Manipulating XML Google Merchant Data using C# and LINQ
Receiving a Google Merchant Data feed (also known as a Google Product Feed) can be fairly easily manipulated on import time using a little C# and LINQ. The feed is basically a XML RSS 2.0 feed with some added properties … Continue reading
Posted in .net, .NET Core, c#, General .NET
Tagged c#, Google Merchant Data, Google Product Feed, LINQ, RSS 2.0, XML
1 Comment
Remove duplicates from XML feed
Apparently XML isn’t dead yet, and today I received a Google Product Feed in the RSS 2.0 XML format. The feed was full of duplicates and my job is to remove them: As you can see, “Product 100” appears twice. … Continue reading
Posted in .net, .NET Core, c#, General .NET
Tagged Google Product Feed, LINQ, RSS 2.0, XDocument, XML
1 Comment
Simple string keyword search using ExtensionMethods and LINQ
This is a case I ran into recently. I need to create a multiple OR condition with LINQ. I have a list of user names and I wish to create a simple search where I can match any first name/middle … Continue reading
Generic lists and Predicates
Recently I was working with a generic list containing my own Favorite class. My Favorite class contains an url and a title: One of the functions on my list is to remove all Favorites with a specific url. I quickly jumped … Continue reading