Is there a way I can trim trailing spaces in a linq query
Posted on 2013-12-18
Is there a way I can trim trailing spaces in a linq query?
query = From row In list
Where row.Working = inputData
In the above example, row.working = "No " and inputData = "No".
I know the best fix is to not allow data into the db with trailing spaces, but for now, I need to work with the data I have.
I have tried trimend and contains and neither worked. but maybe I am not using them correctly? I am kind of a newbie with linq.
thank you for helping me!