I am trying to create a SAP query in order to identify all the cleared items in some company codes with the following parameters: document type, vendors and reversal clearing=blank. I have added another table BSAK2 in order to identify when several accounting documents of different dates have been paid the day before from today. It is assumed that the clearing documents will never have the same document type than the invoices or debit notes.
However when I see the output of the query more than one document number is duplicated. Do you know why some accounting documents are cleared? I tried to join the field accounting document fiscal year and clearing document fiscal year but some entries are still duplicated in the output.
I really appreciate your help,
Thanks a lot!!