What's the easiest way to get a LINQ query (from an SQL database - does that matter?) to order strings naturally?
For example, I'm currently getting these results:
What I'd like is to see is this:
The query I'm using is this:
return from p in dataContext.Projects
orderby p.Name
select p;
There is no built-in way to do this using the .NET framework but I would suggest that you read Natural Sorting in C# for a discussion on the topic and an open-source implementation.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With