无法将类型“System.Linq.IQueryable<AnonymousType#1>”隐式转换为“string”
var test =new string[] { from A in CATOS.TB_BERTHPLANS.Include("LOG_SHIP_MOVE") where (A.ATD >= startDate && A.ATD <= endDate)
select new { yy = A.VSL_CD + A.CALL_YEAR + A.CALL_SEQ }};
//string[] test =string new[] { from A in CATOS.TB_BERTHPLANS where (A.ATD >= startDate && A.ATD <= endDate) select new { yy = A.VSL_CD + A.CALL_YEAR + A.CALL_SEQ } };
var sqljoin = from k in
(from t in
(CATOS.LOG_SHIP_MOVE.Where(t => PTNRs.Contains(t.PTNR_CODE) && (t.BMOVE_TYPE == "DE" || t.BMOVE_TYPE == "ES")
&&test.Contains(t.SHIP_LOG_NO)
))
group t by t.SHIP_LOG_NO into tt
select new
{
//SHIP_LOG_NO = tt.Select(m => m.SHIP_LOG_NO),
SHIP_LOG_NO = tt.Key,
DE_F = tt.Sum(m => m.BMOVE_TYPE + m.FE == "DEF" ? 1 : 0),
DE_E = tt.Sum(m => m.BMOVE_TYPE + m.FE == "DEE" ? 1 : 0),
ES_F = tt.Sum(n => n.BMOVE_TYPE + n.FE == "ESF" ? 1 : 0),
ES_E = tt.Sum(n => n.BMOVE_TYPE + n.FE == "ESE" ? 1 : 0),
RESTOW = tt.Sum(m => m.BMOVE_TYPE == "TB" ? 1 : (m.BMOVE_TYPE == "BT" ? 1 : (m.BMOVE_TYPE == "BB" ? 1 : 0)))
})
join f in
(from A in CATOS.TB_BERTHPLANS.Include("TB_VSL")
select new
{