Its a 2020 1099-R.
It was a 2019 tax year contribution made on 3/5/2020. 2019 taxes filed by 4/15/2020 including this contribution.
Withdraw was made on 5/27/2020 (after 2019 tax filing) and suppose to be for withdraw of this contribution.
There appears to be conflicting interpretation of code 8 and P.
A. Some interpret 8 as contribution+withdraw made in the same "calendar" year. P is different "calendar" year.
B. Some interpret 8 as withdraw for the tax year for the 1099-R and P as previous tax year withdraw.
Called the IRA custodian (Fidelity IRA dept) and also researched online (unfortunately can't post links here). Fidelity's interpretation is A after supervisor consultation internally. They specifically say contribution+withdraw in the same calendar year.
Yours interpretation is B.
Which is correct? Read through IRS directions for 1099-R and Internal Revenue Code 408(d)(4). Unfortunately they don't shed much clarity.
I guess need to get this code correct first (and get a corrected 1099-R if Fidelity is wrong) Then determine the appropriate 2019 Amend and 2020 tax return actions.