My query looks like this:
var products = from p in Products
select new
{
ProductId = p.ProductId,
Description = p.Quantity + " x " p.Price + ", " + p.ItemDescription
};
The reason I am joinin the Description in the query, is I am doing this for multiple querys/objects, to create a history screen (kind of like an audit screen). The screen was taking awhile to load, so I am taking all of the query's and doing a
products.Concat(otherProducts);
The speed has greatly increased (2-3 minutes down to 2-3 seconds), however, if in the example, p.ItemDescription (which is a VARCHAR(50) in the database) is null, but Quantity and Price are not null, then the whole Description field becomes null.
Has anyone encountered this quirk? Anyone know of a way to have it show "4 x 5.99, " instead of just setting it to null?
Any help would be appreciated, I have been trying to work around this for a bit, and don't even know how to really search for this on google.