The correct way would be:
1. post receipt of PO#1, item a x 1.
2. post receipt of PO#2, item a x 2.
3. create new purchase invoice, use function Get Receipt Lines to choose received, but not invoiced lines from PO(s).
When you post invoice created on step 3 the Invoiced Qty is updated in the PO#1 and PO#2.
However this flow is not possible right now, as the "Get Receipt Lines" action is not available.
I logged this. id 217819.
Should be added in one of future updates.
Workaround:
Just create and post invoice #2. As this invoice is not linked to POs, the Qty Received and Qty Invoiced will not be updated in POs. But qty on hand will be updated.
Thanks