Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

HI Experts,Can anybody provide model programs for Aging analysis

Former Member
0 Kudos

Appriciate your service.

Thanks and Regards,

Viswanath

1 ACCEPTED SOLUTION

Former Member
0 Kudos

A simplest way to do this to read BSID, and the group them into buckets (0-30, 30-60, 60-90, etc.) based on BSID-ZFBDT (if your baseline date is the true date for aging) or add bsid-zbd1t to the posting date and age based of that.

But again, there are standard aging reports in SAP and I dont know why you want to develop one.

Albert

4 REPLIES 4

Former Member
0 Kudos

A simplest way to do this to read BSID, and the group them into buckets (0-30, 30-60, 60-90, etc.) based on BSID-ZFBDT (if your baseline date is the true date for aging) or add bsid-zbd1t to the posting date and age based of that.

But again, there are standard aging reports in SAP and I dont know why you want to develop one.

Albert

0 Kudos

Hi Albert

Thanks for your answer.

Can you pls provide programs for the same.

Regards,

Viswanath

Former Member
0 Kudos

You can look at the transaction S_ALR_87012178. But a sample code would be

select bukrs kunnr gjahr belnr budat wrbtr WAERS XBlnR SHKZG

zbd1t vbeln zfbdt

into corresponding fields of table it_bsid from bsid

where kunnr in s_kunnr

and bukrs in s_bukrs

and blart in s_blart

and zfbdt le wa_budat.

"Aging to be considered based on baseline date not postingdate if not change appropriately.

loop at it_bsid.

add it_bsid-zbd1t to it_bsid-budat.

if it_bsid-shkzg = 'H'.

it_bsid-wrbtr = -1 * it_bsid-wrbtr.

endif.

move corresponding it_bsid to output.

l_days = syst-datum - it_bsid-zfbdt.

if l_days le 30.

move it_bsid-wrbtr to output-thirty.

elseif l_days le 60.

move it_bsid-wrbtr to output-sixty.

elseif l_days le 90.

move it_bsid-wrbtr to output-ninety.

elseif l_days le 120.

move it_bsid-wrbtr to output-onetwenty.

else.

move it_bsid-wrbtr to output-over120.

endif.

append output.

endloop.

Albert

Former Member
0 Kudos

check standard SAP program RFFMFG_AGINGBYFUND.

Rob