From 422dc69da7de3dc1a52979f74e14d2cde4eb8be2 Mon Sep 17 00:00:00 2001 From: "Infineon\\Ouellette" Date: Thu, 18 Sep 2025 16:52:45 -0700 Subject: [PATCH] Added in checking that QA stage exists. This allows for lack of QA stage measurements --- LSL2/STPROC/WO_MAT_QA_SERVICES.txt | 62 +++++++++++++++++++++--------- 1 file changed, 43 insertions(+), 19 deletions(-) diff --git a/LSL2/STPROC/WO_MAT_QA_SERVICES.txt b/LSL2/STPROC/WO_MAT_QA_SERVICES.txt index 16c54d9..7f779c3 100644 --- a/LSL2/STPROC/WO_MAT_QA_SERVICES.txt +++ b/LSL2/STPROC/WO_MAT_QA_SERVICES.txt @@ -422,39 +422,58 @@ end service Service GetQAMetComplete(WOMatKey) ErrorMsg = '' - Response = True$ + QAMetComplete = True$ If WOMatKey NE '' then + // Lack of WO_MAT_QA record may not be an error here. Gen5 Products do not have WO_MAT_QA Records If Rowexists('WO_MAT_QA', WOMatKey) then QAMetRec = Database_Services('ReadDataRow', 'WO_MAT_QA', WOMatKey, '', True$, 0, False$) - Stages = QAMetRec - Results = QAMetRec - StageCount = DCount(Stages, @VM) - For I = 1 to StageCount - If Stages<1, I> NE '' then - If Results<1,I> EQ '' then - Response = False$ - end + If Error_Services('NoError') then + Stages = QAMetRec + Results = QAMetRec + StageCount = DCount(Stages, @VM) + QAStagePresent = False$ + For I = 1 to StageCount + If Stages<1, I> EQ 'QA' then + QAStagePresent = True$ + If Results<1,I> EQ '' then + QAMetComplete = False$ + end + end + Until QAMetComplete EQ False$ + Next I + If QAMetComplete EQ True$ AND QAStagePresent = True$ then + QAMUMetComplete = WO_Mat_QA_Services('GetMUWaferQAComplete', WOMatKey) + If Error_Services('NoError') then + If Not(QAMUMetComplete) then + QAMetComplete = False$ + end + end else + ErrorMsg = Error_Services('GetMessage') + end end - Until Response EQ False$ - Next I - end else - Response = True$ + end else + ErrorMsg = Error_Services('GetMessage') + end end end else ErrorMsg = 'Missing WOMatKey parameter.' - Response = False$ end - If ErrorMsg NE '' then - Error_Services('Add', ErrorMsg) + If ErrorMsg EQ '' then + Response = QAMetComplete + end else + Response = False$ + Error_Services('Add', ErrorMsg) end end service Service GetMUWaferQAComplete(WOMatKey) - + + ErrorMsg = '' + If WOMatKey NE '' then Response = True$ WOMatRec = Database_Services('ReadDataRow', 'WO_MAT', WoMatKey, True$, 0, False$) @@ -492,11 +511,16 @@ Service GetMUWaferQAComplete(WOMatKey) Next Box end end else - Error_Services('Add', 'Failed to open WO_MAT record.') + ErrorMsg = 'Failed to open WO_MAT record.' end end else - Error_Services('Add', 'Missing WOMatKey parameter.') + ErrorMsg = 'Missing WOMatKey parameter.' + end + + If ErrorMsg NE '' then + Error_Services('Add', ErrorMsg) end end service +