CREATE VIEW View_MonthReport_InspectionManagement AS /************Ô±¨È¡Êý************/ select im.InspectionId, im.ProjectId, im.CNProfessionalId, im.IsOnceQualified, im.InspectionDate, detail.UnitWorkId from ProcessControl_InspectionManagement as im left join (select distinct(InspectionId),UnitWorkId from ProcessControl_InspectionManagementDetail) as detail on detail.InspectionId = im.InspectionId go