2012 Oct 23 10:28 PM
Hi all,
I've this requirment. I've a report which is filtering some data and is calling formular passing date and installation number. Based on these two factors inside of formular I should read all prices from installation, tarifs and tariftyp facts and based on them show some information in formular. Problem is with tarifs. How should I read all relevant facts from tarifs (for selected installation and date)? In previous version of formular, FM for simulate billing was used, but for some reason client don't want to use this solution anymore. Any ideas?
Best Regards
Marcin Cholewczuk
2012 Oct 29 8:56 AM
Ok, I've found it. ISU_INST_BIVIEW_SELECT as an input one has to give from- and to- date and installation number. As a result in changing parameter in table ianl_rate I'm receiving all relevant rates. With this it's easy to read data from Table EKDI.
Best Regards
Marcin Cholewczuk
2012 Oct 26 8:35 AM
You need to do the following:
1) get the rate category from the installation (field TARIFTYP from table EANLH where AB <= date >= BIS)
2) Get the rate determination from rate determination table (transaction EA87). Here you need to identify all rate types and rates based on your date.
3) Now you need to see for your installation which rates determined at point 2 apply. You need to read tables EASTS to get the rate types (field TARIFART) at the register level, table ETTIFN to get any rate type installation fact (field TARIFART) also based on your date (AB<= date >=BIS).
Also you need to get any rate type from the rate categories rate facts (table EKDI). Also you need to get the rate category facts (field KONDIGR) for each TARIFART
4) After you get all these rate types, base on what you have you need to filter the results you got at point 2. Now you have all the rates that apply along with rate category facts (KONDIGR).
5) Now you just need to read table ETTAF where TARIF = the tariffs you determined above and KONDIGR = KONDIGR determined above. you will get all your rate facts this way.
2012 Oct 26 9:08 AM
Hi,
Thanks for info, but I know how these data are storred in DB. Problem is that this is to complex and if instead of single date I will get as an input a rage it's becoming way to complex. I was hoping that there is an FM, which I could use.
BR
Marcin
2012 Oct 29 8:56 AM
Ok, I've found it. ISU_INST_BIVIEW_SELECT as an input one has to give from- and to- date and installation number. As a result in changing parameter in table ianl_rate I'm receiving all relevant rates. With this it's easy to read data from Table EKDI.
Best Regards
Marcin Cholewczuk