What you describe doesn't appear to be happening on my system (QW 2017 R4). Some transactions have 2 lines in the Investment Transaction report but it is not the Buys. A Sell with capital gains has 1 line for the returned principal (no category) and 1 for the gain or loss. BoughtX's have 2 as I mentioned above. ReinvestDiv's have 2, 1 for the dividend received and one for the shares purchased.The only odd thing I see is that Div's have 2 lines, one blank after the ticker and the second with the ticker, category, and amount
I've enclosed a copy of the report that shows the issue that I'm having. It also shows the related entry as it was entered by the downloaded transaction. Truly, I think that since this has only happened since the Qkn 2017 upgrade, it might be a bug.