initproject

This commit is contained in:
2024-05-08 10:02:08 +08:00
commit 98f03b1780
3859 changed files with 348243 additions and 0 deletions
Binary file not shown.
@@ -0,0 +1,115 @@
ALTER VIEW [dbo].[View_Common_Project_UnitList]
/*淃커꽝宅데貫죗깊柬暠*/
AS
SELECT ProjectUnit.ProjectUnitId
,ProjectUnit.UnitId
,ProjectUnit.ProjectId
,BaseUnit.UnitName
,ProjectUnit.UnitType
,unitType.UnitTypeName
,BaseUnit.UnitCode
,ProjectUnit.ProjectRange
,BaseUnit.Address
,ProjectUnit.InTime
,ProjectUnit.OutTime
,ProjectUnit.Phone
FROM dbo.Project_Unit AS ProjectUnit
LEFT JOIN dbo.Base_Unit AS BaseUnit ON ProjectUnit.UnitId =BaseUnit.UnitId
LEFT JOIN dbo.Base_UnitType unitType ON unitType.UnitTypeId = BaseUnit.UnitTypeId
GO
ALTER VIEW [dbo].[View_Batch_BatchTrustItem]
AS
/********轟愆官辜********/
SELECT
BatchTrustItem.TrustBatchItemId,
BatchTrustItem.TrustBatchId,
BatchTrustItem.PointBatchItemId,
BatchTrustItem.WeldJointId,
BatchTrustItem.CreateDate,
BatchTrustItem.TrustNum,
BatchTrust.TrustType,
BatchTrustItem.RepairNum,
BatchTrust.TrustBatchCode, --官辜데뵀
BatchTrust.ProjectId,
ins.InstallationCode, --陋零
area.WorkAreaCode, --묏혐뵀
pipe.PipelineCode, --밗窟뵀
pipingClass.PipingClassCode, --밗窟된섬
jot.WeldJointCode, --보왯뵀
mat.MaterialCode, --꼼醴
jot.JointArea, --보쌈혐堵
welder.WelderCode AS WelderCode, --보묏뵀
weldType.WeldTypeCode, --보룹잚謹
jot.Dia, --棍쓺
jot.Size, --당쓺
jot.Thickness, --귿비
method.WeldingMethodCode, --보쌈렘랬
rate.DetectionRateCode,
PointBatchItem.PointDate, --듐왯휑퍅
PipingClass.PNO
FROM Batch_BatchTrustItem AS BatchTrustItem
LEFT JOIN dbo.Batch_BatchTrust AS BatchTrust ON BatchTrust.TrustBatchId=BatchTrustItem.TrustBatchId
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.PointBatchItemId=BatchTrustItem.PointBatchItemId
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = PointBatchItem.PointBatchId
LEFT JOIN dbo.Base_DetectionRate rate ON rate.DetectionRateId = point.DetectionRateId
LEFT JOIN dbo.Pipeline_WeldJoint jot ON jot.WeldJointId = BatchTrustItem.WeldJointId
LEFT JOIN dbo.Pipeline_Pipeline pipe ON pipe.PipelineId = jot.PipelineId
LEFT JOIN Base_PipingClass AS pipingClass ON PipingClass.PipingClassId=pipe.PipingClassId
LEFT JOIN dbo.Project_Installation ins ON ins.InstallationId = BatchTrust.InstallationId
LEFT JOIN dbo.Project_WorkArea area ON pipe.WorkAreaId=area.WorkAreaId
LEFT JOIN dbo.Base_WeldType weldType ON weldType.WeldTypeId = jot.WeldTypeId
LEFT JOIN dbo.Welder_Welder welder ON welder.WelderId = jot.BackingWelderId
LEFT JOIN dbo.Base_Material mat ON mat.MaterialId = jot.Material1Id
LEFT JOIN dbo.Base_WeldingMethod method ON method.WeldingMethodId = jot.WeldingMethodId
GO
ALTER VIEW [dbo].[View_NDTBacklogList]
/**********NDE생箕보왯寧응깊***************/
AS
SELECT
PointBatch.ProjectId,
PointBatch.InstallationId,
PointBatch.UnitId,
BatchTrustItem.TrustBatchItemId
,(ISNULL(WorkArea.WorkAreaCode,'')+ '-' + Pipeline.PipelineCode + '-' + ISNULL(Medium.MediumCode,'')) AS ISO_IsoNo --嘉묏혐堵+밗窟뵀+썽醴
,PipingClass.PipingClassName --밗窟된섬
,WeldJoint.WeldJointCode --보왯뵀
,WeldJoint.JointArea --보쌈혐堵
,Welder.WelderCode --보묏뵀
,WeldType.WeldTypeName --보룹잚謹
,CAST(WeldJoint.Size AS NVARCHAR(100)) AS JOT_Dia--棍쓺
,CAST(WeldJoint.Thickness AS NVARCHAR(100)) AS JOT_Sch --귿비
,CONVERT(VARCHAR(100), PointBatchItem.PointDate, 1) AS PointDate --듐왯휑퍅
--,(case when NDTType.SysType ='1' then NDTRate.AcceptGrade else '�' end) as AcceptGrade --'1'槨RT잚謹
,DetectionType.DetectionTypeId
,DetectionType.DetectionTypeName --쇱꿎렘랬
,PipingClass.PNO
FROM Batch_BatchTrustItem AS BatchTrustItem
LEFT JOIN Batch_BatchTrust AS BatchTrust ON BatchTrust.TrustBatchId =BatchTrustItem.TrustBatchId
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.PointBatchItemId =BatchTrustItem.PointBatchItemId
LEFT JOIN Batch_PointBatch AS PointBatch ON PointBatchItem.PointBatchId =PointBatch.PointBatchId
LEFT JOIN Batch_NDEItem ON Batch_NDEItem.TrustBatchItemId = BatchTrustItem.TrustBatchItemId
LEFT JOIN Pipeline_WeldJoint AS WeldJoint ON WeldJoint.WeldJointId =PointBatchItem.WeldJointId
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId =WeldJoint.PipelineId
LEFT JOIN Base_PipingClass AS PipingClass ON PipingClass.PipingClassId =Pipeline.PipingClassId
LEFT JOIN Project_WorkArea AS WorkArea ON WorkArea.WorkAreaId =Pipeline.WorkAreaId
LEFT JOIN Base_Medium AS Medium ON Medium.MediumId =Pipeline.MediumId
LEFT JOIN Welder_Welder AS Welder ON Welder.WelderId =WeldJoint.CoverWelderId
LEFT JOIN Base_WeldType AS WeldType ON WeldType.WeldTypeId =PointBatch.WeldTypeId
LEFT JOIN Base_DetectionType AS DetectionType ON DetectionType.DetectionTypeId =PointBatch.DetectionTypeId
LEFT JOIN Base_DetectionRate AS DetectionRate ON DetectionRate.DetectionRateId =PointBatch.DetectionRateId
WHERE NDEItemID IS NULL OR(NDEItemID IS NOT NULL AND Batch_NDEItem.SubmitDate IS NULL)
GO
@@ -0,0 +1,103 @@
ALTER TABLE dbo.Welder_WelderQualify ADD CheckDate DATETIME NULL
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'考核日期' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Welder_WelderQualify', @level2type=N'COLUMN',@level2name=N'CheckDate'
GO
ALTER TABLE dbo.Batch_PointBatchItem ADD AcceptLevel NVARCHAR(10) NULL
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'合格等级' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Batch_PointBatchItem', @level2type=N'COLUMN',@level2name=N'AcceptLevel'
GO
ALTER VIEW [dbo].[View_Welder_WelderQualify]
AS
/*******焊工资质***********/
SELECT WelderQualify.WelderQualifyId,
WelderQualify.WelderId,
WelderQualify.QualificationItem,
WelderQualify.LimitDate,
WelderQualify.CheckDate,
WelderQualify.WeldingMethodId,
WelderQualify.MaterialId,
WelderQualify.WeldingLocationId,
WelderQualify.ThicknessMin,
WelderQualify.ThicknessMax,
WelderQualify.SizesMin,
WelderQualify.SizesMax,
(CONVERT(NVARCHAR(10),WelderQualify.ThicknessMin)+'-'+(CONVERT(NVARCHAR(10),WelderQualify.ThicknessMax))) AS Thickness,
(CONVERT(NVARCHAR(10),WelderQualify.SizesMin)+'-'+(CONVERT(NVARCHAR(10),WelderQualify.SizesMax))) AS Size,
WelderQualify.Remark,
Welder.WelderCode,
Welder.WelderName,
WeldingMethod.WeldingMethodCode,
WeldingLocation.WeldingLocationCode,
--Material.SteelType,
(CASE WelderQualify.MaterialId WHEN '1' THEN '碳钢'
WHEN '2' THEN '不锈钢'
WHEN '3' THEN '铬钼钢'
WHEN '4' THEN '低合金钢'
WHEN '5' THEN '镍合金钢'
WHEN '6' THEN '钛合金钢'
WHEN '7' THEN '其他'
ELSE '' END) AS SteelTypeName
FROM Welder_WelderQualify AS WelderQualify
LEFT JOIN Welder_Welder AS Welder ON Welder.WelderId=WelderQualify.WelderId
LEFT JOIN Base_WeldingMethod AS WeldingMethod ON WeldingMethod.WeldingMethodId=WelderQualify.WeldingMethodId
--LEFT JOIN Base_Material AS Material ON Material.MaterialId = WelderQualify.MaterialId
LEFT JOIN Base_WeldingLocation AS WeldingLocation ON WeldingLocation.WeldingLocationId=WelderQualify.WeldingLocationId
GO
ALTER VIEW [dbo].[View_Batch_BatchTrustItem]
AS
/********无损委托********/
SELECT
ROW_NUMBER() OVER(ORDER BY WeldJointCode) AS Number,
BatchTrustItem.TrustBatchItemId,
BatchTrustItem.TrustBatchId,
BatchTrustItem.PointBatchItemId,
BatchTrustItem.WeldJointId,
BatchTrustItem.CreateDate,
BatchTrustItem.TrustNum,
BatchTrust.TrustType,
BatchTrustItem.RepairNum,
BatchTrust.TrustBatchCode, --委托单号
BatchTrust.ProjectId,
ins.InstallationCode, --装置
area.WorkAreaCode, --工区号
pipe.PipelineCode, --管线号
pipingClass.PipingClassCode, --管线等级
jot.WeldJointCode, --焊口号
mat.MaterialCode, --材质
jot.JointArea, --焊接区域
welder.WelderCode AS WelderCode, --焊工号
weldType.WeldTypeCode, --焊缝类型
jot.Dia, --外径
jot.Size, --寸径
jot.Thickness, --壁厚
method.WeldingMethodCode, --焊接方法
rate.DetectionRateCode+'%' AS DetectionRateCode,
PointBatchItem.PointDate, --点口日期
PointBatchItem.AcceptLevel, --合格等级
pipe.Sheet, --页数
PipingClass.PNO
FROM Batch_BatchTrustItem AS BatchTrustItem
LEFT JOIN dbo.Batch_BatchTrust AS BatchTrust ON BatchTrust.TrustBatchId=BatchTrustItem.TrustBatchId
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.PointBatchItemId=BatchTrustItem.PointBatchItemId
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = PointBatchItem.PointBatchId
LEFT JOIN dbo.Base_DetectionRate rate ON rate.DetectionRateId = point.DetectionRateId
LEFT JOIN dbo.Pipeline_WeldJoint jot ON jot.WeldJointId = BatchTrustItem.WeldJointId
LEFT JOIN dbo.Pipeline_Pipeline pipe ON pipe.PipelineId = jot.PipelineId
LEFT JOIN Base_PipingClass AS pipingClass ON PipingClass.PipingClassId=pipe.PipingClassId
LEFT JOIN dbo.Project_Installation ins ON ins.InstallationId = BatchTrust.InstallationId
LEFT JOIN dbo.Project_WorkArea area ON pipe.WorkAreaId=area.WorkAreaId
LEFT JOIN dbo.Base_WeldType weldType ON weldType.WeldTypeId = jot.WeldTypeId
LEFT JOIN dbo.Welder_Welder welder ON welder.WelderId = jot.BackingWelderId
LEFT JOIN dbo.Base_Material mat ON mat.MaterialId = jot.Material1Id
LEFT JOIN dbo.Base_WeldingMethod method ON method.WeldingMethodId = jot.WeldingMethodId
GO
Binary file not shown.
@@ -0,0 +1 @@
INSERT INTO Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,ButtonEnName,SortIndex) VALUES('462882FG-CB49-46D5-BA4D-5D82468EBF14','0CA58EC2-7934-49B3-A2C3-327FAD27C541','ɾ³ý','Delete',3)
Binary file not shown.
@@ -0,0 +1,196 @@
ALTER TABLE dbo.Pipeline_WeldJoint ADD IsCancel BIT NULL
GO
EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'角뤠혤句' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Pipeline_WeldJoint', @level2type=N'COLUMN',@level2name=N'IsCancel'
GO
ALTER VIEW [dbo].[View_Pipeline_WeldJoint]
AS
/************보왯斤口柬暠*****************/
SELECT WeldJoint.WeldJointId,
WeldJoint.ProjectId,
WeldJoint.PipelineId,
WeldJoint.WeldJointCode,
WeldJoint.WeldTypeId,
WeldJoint.Material1Id,
WeldJoint.Material2Id,
WeldJoint.Thickness,
WeldJoint.Dia,
WeldJoint.Size,
WeldJoint.JointAttribute,
WeldJoint.JointArea,
WeldJoint.WeldingMethodId,
WeldJoint.IsHotProess,
WeldJoint.WeldingLocationId,
WeldJoint.WeldMatId,
WeldJoint.WeldSilkId,
WeldJoint.GrooveTypeId,
WeldJoint.PipeSegment,
WeldJoint.PipeAssembly1Id,
WeldJoint.PipeAssembly2Id,
WeldJoint.PipeAssemblyCount,
WeldJoint.HeartNo1,
WeldJoint.HeartNo2,
WeldJoint.LastTemp,
WeldJoint.CellTemp,
WeldJoint.PrepareTemp,
WeldJoint.Electricity,
WeldJoint.SystemNumber,
WeldJoint.Remark,
WeldJoint.DoneDin,
WeldJoint.Voltage,
WeldJoint.TestPackageNo,
WeldJoint.WeldingDailyCode,
WeldJoint.WeldingDailyId,
WeldJoint.BackingWelderId,
WeldJoint.CoverWelderId,
WeldJoint.PipingClassId,
WeldJoint.Specification,
Project.ProjectCode,
Project.ProjectName,
Pipeline.PipelineCode,
Pipeline.InstallationId,
Pipeline.UnitId,
Pipeline.SingleNumber,
Pipeline.WorkAreaId,
WeldType.WeldTypeCode,
Material1.MaterialCode AS Material1Code,
Material2.MaterialCode AS Material2Code,
WeldingMethod.WeldingMethodCode,
WeldingLocation.WeldingLocationCode,
WeldMat.ConsumablesCode AS WeldMatCode,
WeldSilk.ConsumablesCode AS WeldSilkCode,
GrooveType.GrooveTypeCode,
CASE WHEN WeldJoint.WeldingDailyId IS NULL THEN '뤠' ELSE '角' END AS Is_hjName,
CASE WHEN WeldJoint.IsHotProess=1 THEN '角' ELSE '뤠' END AS IsHotProessStr,
Components1.ComponentsCode AS ComponentsCode1,
Components2.ComponentsCode AS ComponentsCode2,
BackingWelder.WelderCode AS BackingWelderCode,
BackingWelder.WelderName AS BackingWelderName,
CoverWelder.WelderCode AS CoverWelderCode,
CoverWelder.WelderName AS CoverWelderName,
(CASE WHEN CoverWelder.WelderCode IS NOT NULL AND BackingWelder.WelderCode IS NOT NULL
THEN CoverWelder.WelderCode + '/' + BackingWelder.WelderCode
ELSE (ISNULL(CoverWelder.WelderCode,'') + ISNULL(BackingWelder.WelderCode,'')) END) AS WelderCode, --보묏
(CASE WHEN Material1.MaterialCode IS NOT NULL AND Material2.MaterialCode IS NOT NULL
THEN Material1.MaterialCode + '/' + Material2.MaterialCode
ELSE (ISNULL(Material1.MaterialCode,'') + ISNULL(Material2.MaterialCode,'')) END) AS MaterialCode, --꼼醴
pipingClass.PipingClassCode,
CONVERT(VARCHAR(100), WeldingDaily.WeldingDate, 23) AS WeldingDate,
WeldJoint.IsCancel
FROM Pipeline_WeldJoint AS WeldJoint
LEFT JOIN Base_Project AS Project ON Project.ProjectId=WeldJoint.ProjectId
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId = WeldJoint.PipelineId
LEFT JOIN Base_WeldType AS WeldType ON WeldType.WeldTypeId=WeldJoint.WeldTypeId
LEFT JOIN Base_Material AS Material1 ON Material1.MaterialId = WeldJoint.Material1Id
LEFT JOIN Base_Material AS Material2 ON Material2.MaterialId = WeldJoint.Material2Id
LEFT JOIN Base_WeldingMethod AS WeldingMethod ON WeldingMethod.WeldingMethodId=WeldJoint.WeldingMethodId
LEFT JOIN Base_WeldingLocation AS WeldingLocation ON WeldingLocation.WeldingLocationId=WeldJoint.WeldingLocationId
LEFT JOIN Base_Consumables AS WeldMat ON WeldMat.ConsumablesId=WeldJoint.WeldMatId
LEFT JOIN Base_Consumables AS WeldSilk ON WeldSilk.ConsumablesId=WeldJoint.WeldSilkId
LEFT JOIN Base_GrooveType AS GrooveType ON GrooveType.GrooveTypeId=WeldJoint.GrooveTypeId
LEFT JOIN Base_Components AS Components1 ON Components1.ComponentsId = WeldJoint.PipeAssembly1Id
LEFT JOIN Base_Components AS Components2 ON Components2.ComponentsId = WeldJoint.PipeAssembly2Id
LEFT JOIN Welder_Welder AS BackingWelder ON BackingWelder.WelderId=WeldJoint.BackingWelderId
LEFT JOIN Welder_Welder AS CoverWelder ON CoverWelder.WelderId=WeldJoint.CoverWelderId
LEFT JOIN Pipeline_WeldingDaily AS WeldingDaily ON WeldingDaily.WeldingDailyId=WeldJoint.WeldingDailyId
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId=WeldJoint.PipingClassId
GO
ALTER PROC [dbo].[sp_rpt_OutstandingWelds]
@projectId NVARCHAR(50) = NULL,
@unitId NVARCHAR(50) = NULL,
@installationId NVARCHAR(50) = NULL,
@workAreaId NVARCHAR(50) = NULL,
@pipingClassId NVARCHAR(50) = NULL,
@weldTypeId NVARCHAR(50) = NULL,
@pipelineCode VARCHAR(50) = NULL
AS
/*灌보보왯헌데*/
SELECT
weldJoint.ProjectId
,weldJoint.WeldJointId
,pipeline.PipelineId
,pipeline.WorkAreaId
,pipeline.UnitId
,workArea.InstallationId
,workArea.WorkAreaCode
,weldType.WeldTypeCode
,pipingClass.PipingClassCode
,pipeline.PipelineCode
,weldJoint.WeldJointCode
,weldJoint.WeldingDailyId
,weldJoint.Size
,weldJoint.Thickness
,weldJoint.PipingClassId
,weldJoint.WeldTypeId
,weldJoint.JointArea
FROM Pipeline_WeldJoint AS weldJoint
LEFT JOIN Pipeline_Pipeline AS pipeline ON weldJoint.PipelineId = pipeline.PipelineId
LEFT JOIN Project_WorkArea AS workArea ON workArea.WorkAreaId = pipeline.WorkAreaId
LEFT JOIN Base_WeldType AS weldType ON weldType.WeldTypeId = weldJoint.WeldTypeId
LEFT JOIN Base_PipingClass AS pipingClass ON pipingClass.PipingClassId = weldJoint.PipingClassId
WHERE (weldJoint.ProjectId=@projectId OR @projectId IS NULL)
AND (pipeline.UnitId=@unitId OR @unitId IS NULL)
AND (workArea.InstallationId=@installationId OR @installationId IS NULL)
AND (pipeline.WorkAreaId=@workAreaId OR @workAreaId IS NULL)
AND (weldJoint.PipingClassId=@pipingClassId OR @pipingClassId IS NULL)
AND (weldJoint.WeldTypeId=@weldTypeId OR @weldTypeId IS NULL)
AND ((pipeline.PipelineCode LIKE '%'+@pipelineCode+'%') OR @pipelineCode IS NULL)
AND (weldJoint.IsCancel=0 OR weldJoint.IsCancel IS NULL)
GO
ALTER VIEW [dbo].[View_NDTBacklogList]
/**********NDE생箕보왯寧응깊***************/
AS
SELECT
PointBatch.ProjectId,
PointBatch.InstallationId,
PointBatch.UnitId,
BatchTrustItem.TrustBatchItemId
,(WorkArea.WorkAreaCode + '-' + Pipeline.PipelineCode + '-' + Medium.MediumCode) AS ISO_IsoNo --嘉묏혐堵+밗窟뵀+썽醴
,PipingClass.PipingClassName --밗窟된섬
,WeldJoint.WeldJointCode --보왯뵀
,WeldJoint.JointArea --보쌈혐堵
,Welder.WelderCode --보묏뵀
,WeldType.WeldTypeName --보룹잚謹
,CAST(WeldJoint.Size AS NVARCHAR(100)) AS JOT_Dia--棍쓺
,CAST(WeldJoint.Thickness AS NVARCHAR(100)) AS JOT_Sch --귿비
,CONVERT(VARCHAR(100), PointBatchItem.PointDate, 1) AS PointDate --듐왯휑퍅
--,(case when NDTType.SysType ='1' then NDTRate.AcceptGrade else '�' end) as AcceptGrade --'1'槨RT잚謹
,DetectionType.DetectionTypeId
,DetectionType.DetectionTypeName --쇱꿎렘랬
,PipingClass.PNO
,BatchTrust.TrustBatchCode
FROM Batch_BatchTrustItem AS BatchTrustItem
LEFT JOIN Batch_BatchTrust AS BatchTrust ON BatchTrust.TrustBatchId =BatchTrustItem.TrustBatchId
LEFT JOIN Batch_PointBatchItem AS PointBatchItem ON PointBatchItem.PointBatchItemId =BatchTrustItem.PointBatchItemId
LEFT JOIN Batch_PointBatch AS PointBatch ON PointBatchItem.PointBatchId =PointBatch.PointBatchId
LEFT JOIN Batch_NDEItem ON Batch_NDEItem.TrustBatchItemId = BatchTrustItem.TrustBatchItemId
LEFT JOIN Pipeline_WeldJoint AS WeldJoint ON WeldJoint.WeldJointId =PointBatchItem.WeldJointId
LEFT JOIN Pipeline_Pipeline AS Pipeline ON Pipeline.PipelineId =WeldJoint.PipelineId
LEFT JOIN Base_PipingClass AS PipingClass ON PipingClass.PipingClassId =Pipeline.PipingClassId
LEFT JOIN Project_WorkArea AS WorkArea ON WorkArea.WorkAreaId =Pipeline.WorkAreaId
LEFT JOIN Base_Medium AS Medium ON Medium.MediumId =Pipeline.MediumId
LEFT JOIN Welder_Welder AS Welder ON Welder.WelderId =WeldJoint.CoverWelderId
LEFT JOIN Base_WeldType AS WeldType ON WeldType.WeldTypeId =PointBatch.WeldTypeId
LEFT JOIN Base_DetectionType AS DetectionType ON DetectionType.DetectionTypeId =PointBatch.DetectionTypeId
LEFT JOIN Base_DetectionRate AS DetectionRate ON DetectionRate.DetectionRateId =PointBatch.DetectionRateId
WHERE NDEItemID IS NULL OR(NDEItemID IS NOT NULL AND Batch_NDEItem.SubmitDate IS NULL)
GO
Binary file not shown.
Binary file not shown.