Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Is there a better way to right this IF Statement? This load currently takes 40 minutes on 10 Millions records.
InterfaceTraffic1:
Load
*, IF(sum(InBandwidth)+sum(OutBandwidth)=0,0,
IF(sum(InBandwidth)=0,sum(OutBandwidth/OutBandwidth) * 100,
IF(sum(OutBandwidth),(sum(In_Averagebps)/sum(InBandwidth)) * 100,
sum(Out_Averagebps/OutBandwidth)+sum(In_Averagebps/InBandwidth)*50))) AS AVERAGE_of_CircuitUtil_AvgRecvXmit2
RESIDENT InterfaceTrafficDetailTemp
GROUP BY InterfaceID, NodeID,In_Averagebps,Out_Averagebps,InBandwidth,OutBandwidth,InterfaceName,BandwidthandCircuit;
Hi,
This is not what you are asking exactly, but just another idea:
Did you try storing the resident InterfaceTrafficDetailTemp table into a qvd file, and then load the InterfaceTraffic1 table from the qvd file?
Regards,