Why are you give the component material A and material B both in PO?
You business scenario is like that
From material C to Material B
Then material B to Material A.
You have sent the material C to vendor and you are receiving material A from vendor.
The same issue discussed in a recent thread
Please read the thread and if you have any doubt, then share with us.
material provide to vendor is at the last level of BOM component (ROH)