Reputation: 87
I have a challenge to use Select new
Normally we do
var record = from s in db.Settings
select new
{
myID = s.ID,
customName = s.PkGuid
};
But we can't do Select new if I have like:
CacheHelper.Settings().Select(a => ???????)
Any one?!
Thanks :)
Upvotes: 0
Views: 91
Reputation: 8129
You made me uncertain for 30ms!
var record = CacheHelper.Settings().Select(a => new {
myID = a.ID,
customName = a.PkGuid
});
Upvotes: 1