Hi,
As you want to post all 5000 material code in single material document, I don't think it is possible, as when you post the Goods movement, for each line item 2 FI entries are created in BSEG table and one FI document can have max 999 line items as the field BUZEI is CHAR 3, posting 5000 material in single document is not possible.
Regards,
Zafar