FBL1N and Z Report of BSIK and BSAK
As i made a vendor report as like as in FBL1N like as provided in report radio button of open item, cleared items and all items.
when i am executing FBL1N and providing their vendor number and company code and selecting radio button open items and giving date as 06.04.2012
and executing it than report shows 4 records in which 3 records coming from BSIK table(which is for open items) and also getting one entry from BSAK(which is for cleared items) and in my report i am taking records only from BSIK table for open items radio button so my report showing 3 records so i want to know which field is used to make difference between these records to select from BSAK or how to get that 1 records showing in transaction FBL1N in my report.
Raymond Giuseppi replied
The key is the clearing date, if an item was cleared after the reference date it is displayed as a non-cleared item.
* Not cleared at ref_date
SELECT * FROM BSIK WHERE BUDAT LE ref_date
SELECT * FROM BSAK WHERE AUGDT GT ref_date AND BUDAT LE ref_date
* Cleared at ref_date
SELECT * FROM BSAK WHERE AUGDT LE ref_date " AND BUDAT LE ref_date