Quantcast
Channel: SCN: Message List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 9165

Re: Moving Average Calculation in HANA.

$
0
0

Hi,

 

It's on page 92 of http://help.sap.com/hana/SAP_HANA_Business_Function_Library_BFL_en.pdf. If you want to use those functions in a local table in a SQLScript Procedure or Scripted Calc View then you can do so, just replace the output table with a local table in SQLScript.

 

CALL _SYS_AFL.AFLBFL_MOVINGAVERAGEANDSUM_PROC(BFL_MAMS_ORIGINAL_TBL, BFL_MAMS_AVERAGESTYLE_TBL, BFL_MAMS_AVERAGEMETHOD_TBL, BFL_MAMS_PRIME_TBL, BFL_MAMS_AVERAGEPERIODS_TBL, BFL_MAMS_WEIGHTINGS_TBL, :lt_results);

 

You can create the tabletypes and weighting tables in advance, or you can do the weightings dynamically using local input variables and arrays.

 

If you're still stuck, paste your DDL, Data and Code and someone will help you out.

 

John


Viewing all articles
Browse latest Browse all 9165

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>