M
macroapa
Hi, I have a select query that takes about 5 seconds to run. If I
take the same query and turn it into a make table query, it takes
about 15 mins to run. I'm almost at the stage of running a SELECT
query and copying the data and pasting into the table. Is there
anything I can do to increase performance of the make table query?
=============================================================================
SELECT sql
SELECT tblaaTRTvsExtTRT.workitemid, tblaaTRTvsExtTRT.stepname,
tblaaTRTvsExtTRT.workitemstepid, tblaaTRTvsExtTRT.Available,
tblaaTRTvsExtTRT.Worked, tblaaTRTvsExtTRT.StepStarted,
tblaaTRTvsExtTRT.TouchStopped, qryTrueStepStop.TrueStepStop,
tblaaTRTvsExtTRT.workitemdate, tblaaTRTvsExtTRT.status_desc,
tblaaTRTvsExtTRT.wistopdate, workdaysdiff([available],[worked]) AS
aaTRT, workdaysdiff([stepstarted],[truestepstop]) AS wholeTRT
FROM tblaaTRTvsExtTRT INNER JOIN qryTrueStepStop ON
tblaaTRTvsExtTRT.workitemstepid = qryTrueStepStop.workitemstepid;
=============================================================================
Make table sql
SELECT tblaaTRTvsExtTRT.workitemid, tblaaTRTvsExtTRT.stepname,
tblaxTRTvsExtTRT.workitemstepid, tblaaTRTvsExtTRT.Available,
tblaaTRTvsExtTRT.Worked, tblaaTRTvsExtTRT.StepStarted,
tblaaTRTvsExtTRT.TouchStopped, qryTrueStepStop.TrueStepStop,
tblaaTRTvsExtTRT.workitemdate, tblaaTRTvsExtTRT.status_desc,
tblaaTRTvsExtTRT.wistopdate, workdaysdiff([available],[worked]) AS
aaTRT, workdaysdiff([stepstarted],[truestepstop]) AS wholeTRT INTO
tblaaTRTandWholeTRT
FROM tblaaTRTvsExtTRT INNER JOIN qryTrueStepStop ON
tblaaTRTvsExtTRT.workitemstepid = qryTrueStepStop.workitemstepid;
take the same query and turn it into a make table query, it takes
about 15 mins to run. I'm almost at the stage of running a SELECT
query and copying the data and pasting into the table. Is there
anything I can do to increase performance of the make table query?
=============================================================================
SELECT sql
SELECT tblaaTRTvsExtTRT.workitemid, tblaaTRTvsExtTRT.stepname,
tblaaTRTvsExtTRT.workitemstepid, tblaaTRTvsExtTRT.Available,
tblaaTRTvsExtTRT.Worked, tblaaTRTvsExtTRT.StepStarted,
tblaaTRTvsExtTRT.TouchStopped, qryTrueStepStop.TrueStepStop,
tblaaTRTvsExtTRT.workitemdate, tblaaTRTvsExtTRT.status_desc,
tblaaTRTvsExtTRT.wistopdate, workdaysdiff([available],[worked]) AS
aaTRT, workdaysdiff([stepstarted],[truestepstop]) AS wholeTRT
FROM tblaaTRTvsExtTRT INNER JOIN qryTrueStepStop ON
tblaaTRTvsExtTRT.workitemstepid = qryTrueStepStop.workitemstepid;
=============================================================================
Make table sql
SELECT tblaaTRTvsExtTRT.workitemid, tblaaTRTvsExtTRT.stepname,
tblaxTRTvsExtTRT.workitemstepid, tblaaTRTvsExtTRT.Available,
tblaaTRTvsExtTRT.Worked, tblaaTRTvsExtTRT.StepStarted,
tblaaTRTvsExtTRT.TouchStopped, qryTrueStepStop.TrueStepStop,
tblaaTRTvsExtTRT.workitemdate, tblaaTRTvsExtTRT.status_desc,
tblaaTRTvsExtTRT.wistopdate, workdaysdiff([available],[worked]) AS
aaTRT, workdaysdiff([stepstarted],[truestepstop]) AS wholeTRT INTO
tblaaTRTandWholeTRT
FROM tblaaTRTvsExtTRT INNER JOIN qryTrueStepStop ON
tblaaTRTvsExtTRT.workitemstepid = qryTrueStepStop.workitemstepid;