cancel
Showing results for 
Search instead for 
Did you mean: 

BSID Vs BSAD

Former Member
0 Kudos

Hello Friends,

I'm preparing a Z report, in that i have to capture the customer balances for a particular date. But the problem is all the open line items in BSID are moving to BSAD after done the payment against to these line items. In this situation balance amount is changing in the report. what is the way to capture the O/S as on a particular date?

ex: Customer X O/s as on 01.01.09 is 1000

Later on i've made the paymnet 500 as on 03.01.09

if i run the report as on 01.01.09 now the balance is appearing as 500 which is nor correct.

can anyone provide me the table logic for this issue?

Thanks

Swapna

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Dear Swapna

I think you are using FBL5N T.Code to view open items of a Customer. All open items will be laid in BSID, whenever these will be cleared and it will be moved to BSAD for cleared items. So, make sure in FBL5N put the date against open items from and to date, between which date you wants to see them. If you have given cleared date then it will shows in BSAD table.

Regards

Chinnu

Former Member
0 Kudos

Hi Chinnu,

I'm not looking FBL5N, i'm preparing a Z report.

i need logic for the Z report.

Former Member
0 Kudos

Hi,

Can you please check as per the logic given earlier if it is working.

Thanks and Regards,

Anit

Former Member
0 Kudos

Hi,

Should i follow the following logic

BSID => BUDAT is < / =

BSAD => AUGDT is >/=

& BUDAT is </=

Let me know

Former Member
0 Kudos

Hi Swapna,

This logic should work.

Thanks and Regards,

Anit

Former Member
0 Kudos

Dear Anit,

Thanks for your support. I have applied the same logic which you 've given but logic is failed for some customers.

i'll come back again.

Thanks

Swapna

Former Member
0 Kudos

Hi

In your Z report take the logic like, take the items from BSID and BSAD, compare the items in BSAD with the items available in BSE_clr and take the line items matching with bse_clr for compiling. This will give you the line items open as at a particular date.

Regards,

Lakshmanan Krishnan

Former Member
0 Kudos

Hi Anit,

Thanks alot for your logic.

SAHANI.

Former Member
0 Kudos

Hi Swapna,

Glad to be of help.

Thanks and Regards,

Anit

Answers (4)

Answers (4)

uygur_burak
Active Contributor
0 Kudos

Hello,

If you want to get open line items at key date.

You can use selects below.


DATA : gt_bsid LIKE bsid OCCURS 0 WITH HEADER LINE.

SELECT * 
  INTO TABLE gt_bsid
  FROM bsid
  WHERE bukrs EQ p_bukrs  " parametre for company code at selection-screen.
    AND kunnr IN s_kunnr  " select-options for customer code
    AND budat LE p_kdate. " parametre for key date

SELECT * 
  APPENDING CORRESPONDING FIELDS OF TABLE gt_bsid
  FROM bsad
  WHERE bukrs EQ p_bukrs  " parametre for company code at selection-screen.
    AND kunnr IN s_kunnr  " select-options for customer code
    AND augdt GT p_kdate  " if clearing date(AUGDT) is greater than key date, at key date this line is open.
    AND budat LE p_kdate. " parametre for key date  

You can add more "where conditions" using key field on table for performance improiving .

Regards,

Burak

Former Member
0 Kudos

Use function module BAPI_AR_ACC_GETKEYDATEBALANCE.

Regards

Mukesh

Former Member
0 Kudos

Hi,

For open line items to appear in the z-report, give the logic to pick up those line items from BSAD table, which falls between the clearing date and the date mentioned in z-report (By the customer).

This will make sure that status of open items is correctly shown in the report.

Let me know if this worked.

Regards

K Khatri

Former Member
0 Kudos

Hi,

From BSAD you should pick documents that have got cleared after date given as input. AS per your example any document in BSAD which has clearing date (AUGDT) after 01.01.09 but posted before 01.01.09, should be included in the report.

Thanks and Regards,

Anit

Edited by: Anit Mangat on Jul 10, 2009 8:21 AM