我是 LinQ 的 Newbi,我对 linQ 中的 group by 有疑问。
我想这样查询:
选择 MAX(TCheckpointGrouping.Id) 作为 CheckpointGroupingId, MAX(TCheckpointGrouping.MCheckpointId) AS CheckpointId, MAX(MCheckpoint.Name) 作为检查点名称, MAX(CAST(MCheckpoint.IsMajor AS VARCHAR)) 作为 IsMajor, MAX(TCheckpointGrouping.MIndicatorId) AS IndicatorId, MAX(MIndicator.Name) 作为指标名称, MAX(MCriteria.Id) 作为 CriteriaId, MAX(MCriteria.Name) AS CriteriaName, MAX(MPrinciple.Id) AS PrincipleId, MAX(MPrinciple.Name) AS PrincipalName, MAX(TCheckpointGrouping.RelationToCheckPoint) AS RelationToCheckPoint 来自 TCheckpointGrouping 在 MCheckpoint.Id = TCheckpointGrouping.MCheckpointId 上内连接 MCheckpoint 内部连接 MIndicator 上 MIndicator.Id = TCheckpointGrouping.MIndicatorId MCriteria.Id = MIndicator.MCriteriaId 上的内部连接 MCriteria 在 MPrinciple.Id = MCriteria.MPrincipleId 上内连接 MPrinciple 通过...分组 TCheckpointGrouping.MCheckpointId, TCheckpointGrouping.MIndicatorId
如何将上面的查询转换为 LinQ (VB.NET)
谢谢最好的问候