I have a query(TestQry1) that combines results from 2 tables together(tbl_AVUM_Scored_Data)and(
tbl_SME_AVUM_Edit), It has IETM_ID and edit information.
Attachment 5058
Code:
SELECT tbl_AVUM_Scored_Data.Record_ID, tbl_AVUM_Scored_Data.EI_ID, tbl_AVUM_Scored_Data.Event_Date,
tbl_AVUM_Scored_Data.Event_No, tbl_AVUM_Scored_Data.Sys_Code, tbl_AVUM_Scored_Data.IETM_ID,
tbl_SME_AVUM_Edit.MOS_ID, tbl_SME_AVUM_Edit.Time
FROM tbl_AVUM_Scored_Data LEFT JOIN tbl_SME_AVUM_Edit ON tbl_AVUM_Scored_Data.Record_ID =
tbl_SME_AVUM_Edit.Record_ID
GROUP BY tbl_AVUM_Scored_Data.Record_ID, tbl_AVUM_Scored_Data.EI_ID, tbl_AVUM_Scored_Data.Event_Date,
tbl_AVUM_Scored_Data.Event_No, tbl_AVUM_Scored_Data.Sys_Code, tbl_AVUM_Scored_Data.IETM_ID,
tbl_SME_AVUM_Edit.MOS_ID, tbl_SME_AVUM_Edit.Time;
Code:
tbl_AVUM_Scored_Data
Record_ID
EI_ID
Event_Date
Event_No
Sys_Code
IETM_ID
TimeStamp
Code:
tbl_SME_AVUM_Edit
Record_ID
Maint_Funct
MOS_ID
Time
Comments
Date Added
I use another query(qryTest2) to pull mos and time data from another table(tbl_List_SiteVisit2) and combine the
results from the first query(TestQry1) to add everything together.
Attachment 5060
qryTest2
Code:
SELECT TestQry1.EI_ID, TestQry1.Event_Date, TestQry1.Event_No, TestQry1.Sys_Code, tbl_List_SiteVisit2.MOS_ID,
Sum(Int(10*([tbl_List_SiteVisit2].[Quantity]*[tbl_List_SiteVisit2].[Time]))/10) AS ManHours
FROM TestQry1 LEFT JOIN tbl_List_SiteVisit2 ON TestQry1.IETM_ID=tbl_List_SiteVisit2.IETM_ID
GROUP BY TestQry1.EI_ID, TestQry1.Event_Date, TestQry1.Event_No, TestQry1.Sys_Code, tbl_List_SiteVisit2.MOS_ID;
Code:
tbl_List_SiteVisit2
ID
IETM_ID
Maint_Funct
MOS_ID
Quantity
Time
TimeStamp
Attachment 5059
My issue is the calulation for qrytest2 works fine except when I have to add the edit information, it gets
recorded in my tbl_SME_AVUM_Edit, however it does not get added to the final mos time calculation that is displayed in the AVUM Totals Listbox which is based off of the qryTest2.
Any thoughts...I will give more information for clarity if needed.