57 lines
2.0 KiB
MySQL
57 lines
2.0 KiB
MySQL
|
|
|
|||
|
|
|
|||
|
|
ALTER VIEW [dbo].[View_DCGL_CheckRectifyListFromSUB]
|
|||
|
|
AS
|
|||
|
|
/*<EFBFBD>ӹ<EFBFBD>˾<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ĵ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͼ*/
|
|||
|
|
SELECT CheckRectifyItem.CheckRectifyItemId
|
|||
|
|
,CheckRectifyItem.CheckRectifyId
|
|||
|
|
,CheckRectifyItem.NoticeItemId
|
|||
|
|
,CheckRectifyItem.ConfirmMan
|
|||
|
|
,CheckRectifyItem.ConfirmManName
|
|||
|
|
,CheckRectifyItem.ConfirmDate
|
|||
|
|
,CheckRectifyItem.OrderEndDate
|
|||
|
|
,CheckRectifyItem.OrderEndPerson
|
|||
|
|
,CheckRectifyItem.RealEndDate
|
|||
|
|
,CheckRectifyItem.Verification
|
|||
|
|
,CheckRectify.CheckRectifyCode
|
|||
|
|
,CheckRectify.ProjectId
|
|||
|
|
,CheckRectify.UnitId
|
|||
|
|
,CheckRectify.CheckDate
|
|||
|
|
,CheckRectify.IssueMan
|
|||
|
|
,CheckRectify.IssueDate
|
|||
|
|
,CheckRectify.HandleState
|
|||
|
|
,NoticeItem.ProblemTypes AS ProblemTypes
|
|||
|
|
,NoticeItem.RiskLevel AS RiskLevel
|
|||
|
|
,NoticeItem.SortIndex AS SortIndex
|
|||
|
|
,NoticeItem.Situation AS Situation
|
|||
|
|
,'' AS WorkType
|
|||
|
|
,'' AS DangerPoint
|
|||
|
|
,'<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⣩<EFBFBD><EFBFBD><EFBFBD><EFBFBD>:'+NoticeItem.Describe+';<3B><><EFBFBD>ݱ<EFBFBD>:'+NoticeItem.Standards+';<3B><><EFBFBD><EFBFBD>:'+NoticeItem.Advice AS RiskExists
|
|||
|
|
,'' AS IsProject
|
|||
|
|
,'' AS CheckMan
|
|||
|
|
,'' AS SubjectUnitMan
|
|||
|
|
--,Table5Item.SortIndex
|
|||
|
|
--,Table5Item.WorkType
|
|||
|
|
--,Table5Item.DangerPoint
|
|||
|
|
--,Table5Item.RiskExists
|
|||
|
|
--,Table5Item.IsProject
|
|||
|
|
--,Table5Item.CheckMan
|
|||
|
|
--,Table5Item.SubjectUnitMan
|
|||
|
|
,AttachFile.AttachFileId
|
|||
|
|
,AttachFile.ToKeyId
|
|||
|
|
,AttachFile.AttachSource
|
|||
|
|
,AttachFile.AttachUrl
|
|||
|
|
,AttachFile2.AttachFileId AS AttachFileId2
|
|||
|
|
,AttachFile2.ToKeyId AS ToKeyId2
|
|||
|
|
,AttachFile2.AttachSource AS AttachSource2
|
|||
|
|
,AttachFile2.AttachUrl AS AttachUrl2
|
|||
|
|
FROM dbo.DCGL_Check_CheckRectifyItem AS CheckRectifyItem
|
|||
|
|
LEFT JOIN dbo.DCGL_Check_CheckRectify AS CheckRectify ON CheckRectifyItem.CheckRectifyid=CheckRectify.CheckRectifyId
|
|||
|
|
--LEFT JOIN dbo.Check_CheckInfo_Table5Item as Table5Item on CheckRectifyItem.Table5ItemId=Table5Item.ID
|
|||
|
|
LEFT JOIN DCGL_Check_CheckInfo_TableNoticeItem AS NoticeItem ON CheckRectifyItem.NoticeItemId=NoticeItem.ID
|
|||
|
|
LEFT JOIN dbo.AttachFile AS AttachFile on AttachFile.ToKeyId =CheckRectifyItem.NoticeItemId
|
|||
|
|
LEFT JOIN dbo.AttachFile AS AttachFile2 on AttachFile2.ToKeyId =CheckRectifyItem.CheckRectifyItemId
|
|||
|
|
GO
|
|||
|
|
|
|||
|
|
|