Cube is 12 dims, the max # of data points is 3 * 10 * 604 * 4 * 1276 * 99 * 556 * 11 * 4 * 130 * 8 * 25616 = 5,967,276,689,533,970,000,000

I need to extract in a tabular format data from 3 of those dims down the left side, with years spanning 2008 to 2023 (consolidations of months) across the top for one of our users. The issue is that the TI i have written to extract this is taking too much RAM off the server. Its a squeak from 3GB when it finishes so any user grabbing data that has yet to be cached is likely to kill it. Of the 3 dims i am listing down the left, one has 3 elements, another about 50 and the last is circa 22,000. The final output is only about 7,500 rows of data, but its the sheer data it needs to look at (all the other dims are top level consolidations) that is killing it.
My TI is based on a cube view. It only selects the elements it requires with the exception of the year where i have to pick the top level. The TI then has to cycle thru each of the years i need for each data point so that i can generate the tabular formatted export;
Code: Select all
#adds header record to output file
IF ( n = 1 );
AsciiOutput ( FileOut , 'Status' , 'Contract' , 'Organisation' , 'Resource' , '2008' , '2009' , '2010' , '2011' , '2012' , '2013' , '2014' ,
'2015' , '2016' , '2017' , '2018' , '2019' , '2020' , '2021' , '2022' , '2023' ) ;
EndIF;
n = n + 1;
#find value for each year
m2008 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2008' , Version , measure );
m2009 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2009' , Version , measure );
m2010 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2010' , Version , measure );
m2011 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2011' , Version , measure );
m2012 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2012' , Version , measure );
m2013 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2013' , Version , measure );
m2014 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2014' , Version , measure );
m2015 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2015' , Version , measure );
m2016 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2016' , Version , measure );
m2017 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2017' , Version , measure );
m2018 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2018' , Version , measure );
m2019 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2019' , Version , measure );
m2020 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2020' , Version , measure );
m2021 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2021' , Version , measure );
m2022 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2022' , Version , measure );
m2023 = CellGetN ( 'Demand' , ppd , wbs , obs , rbs , nom , Site , res_source , status , risk , '2023' , Version , measure );
#output to file
AsciiOutput ( FileOut , status , wbs , ppd , rbs , NumberToString ( m2008 ) , NumberToString ( m2009 ) , NumberToString ( m2010 ) , NumberToString ( m
2011 ) ,
NumberToString ( m2012 ) , NumberToString ( m2013 ) , NumberToString ( m2014 ) , NumberToString ( m2015 ) , NumberToString ( m2016 ) , NumberToString
( m2017 ) , NumberToString ( m2018 ) , NumberToString ( m2019 ) , NumberToString ( m2020 ) , NumberToString ( m2021 ) , NumberToString ( m2022 ) , Nu
mberToString ( m2023) );
TIA