这是我的代码
var personalInfoQuery = from t in crnnsupContext.Tombstones.Include("ProvState")
join n in crnnsupContext.NursingSchools
on t.NursingSchool equals n.SchoolID
where t.RegNumber == _username
select new { t, n };
然后我尝试将个人信息查询放入列表中,如下:
List<> personalInfoResult = personalInfoQuery.ToList();
但是如何在列表中表示匿名类型?
我需要将其插入缓存中,
所以Cache.Insert("personalInfo", personalInfoQuery.ToList())
然后Cache["personalInfo"]
变成了一个对象,我该如何从中读取数据?