Finding a faster query for USQL

By: Johnathon Wright on: December 17, 2012

"select sum(NOIAMOUNT) FROM NOI WHERE NOIALLOC_DATE = { d '2012-12-05' };" ~ instant

select NOITRNNUMBER, sum(NOIAMOUNT) FROM NOI WHERE NOIALLOCDATE = { d '2012-12-05' } GROUP BY NOI.NOITRN_NUMBER; ~ instant

select TRANTYPES.TRNNAME, NOITRNNUMBER, sum(NOIAMOUNT) FROM NOI, TRANTYPES WHERE NOIALLOCDATE = { d '2012-12-05' } AND TRANTYPES.TRNNUMBER = NOI.NOITRNNUMBER GROUP BY NOI.NOITRNNUMBER, TRANTYPES.TRNNAME;

~125s

select MAX(TRANTYPES.TRNNAME), NOITRNNUMBER, sum(NOIAMOUNT) FROM NOI, TRANTYPES WHERE NOIALLOCDATE = { d '2012-12-05' } AND TRANTYPES.TRNNUMBER = NOI.NOITRNNUMBER GROUP BY NOI.NOITRNNUMBER;

~ 126s





Comments:

Just checking that you are human. What would be the result of this code?

a = 3*(4/2); b = 1; a+b

Ali said: The way you pack your belongings can have a significant impact on their safety during the move. Use high-quality boxes and packing materials to protect fragile items. Auto Shipping Rates Wheeling

Back