WARSAW/HOUSTON, May 14 (Reuters) - A Swiss unit of Polish refiner Orlen paid two Dubai-based intermediary companies $330 million for Venezuelan oil, but Venezuela's state oil company PDVSA never received the money, according to sources and a document seen by Reuters.

Prosecutors in Poland are investigating the loss of about $400 million by Orlen Trading Switzerland (OTS) in prepayments, mostly for Venezuelan oil, in what has become a politically charged story in Warsaw.

State-controlled Orlen agreed last year to buy several oil cargoes from Venezuela during a temporary softening by Washington of sanctions on the country, and sent supertankers to pick them up.

But Orlen said last month it had scrapped the contracts after the tankers failed to load for months and as a U.S. licence temporarily allowing oil exports from Venezuela was set to expire in mid-April.

Orlen's statement came after management changes at Orlen and OTS in February, and after a new pro-European Polish government led by Prime Minister Donald Tusk raised questions about the operations of the Swiss unit.

The new government has pledged to purge state-controlled companies of people it considers political nominees of the previous ruling Law and Justice party.

However, Orlen's former head of trading, Michal Rog, told Polish media last month that OTS's losses resulted from the cancellation of the deals by Orlen's new management.

According to a document reviewed by Reuters covering transfers and receipts related to the trades, OTS made a series of transfers totalling $230 million to Dubai-based Hannon International Middle East DMCC and another $100 million to Dubai-based Horizon Global. The transfers were made in December.

Details of the transfers have not previously been reported.

Orlen said in April it had not worked before with the intermediary companies, without naming them.

Neither Hannon nor Horizon have ever been direct PDVSA clients, according to a PDVSA source and internal PDVSA shipping records, reviewed by Reuters.

Hannon International Middle East DMCC did not reply to phone calls and WhatsApp messages seeking comment. Horizon Global declined to comment, citing ongoing arbitration with OTS.

Orlen declined to comment, citing ongoing investigations, while PDVSA and Venezuela's oil ministry did not reply to requests for comment.

Investigators are examining the role and actions of people from Orlen and OTS, a spokesperson for Warsaw's regional prosecutor said, without providing further details.

A source familiar with the matter said Orlen had been told that PDVSA never received any money for its oil from Hannon or Horizon.

A PDVSA source said the company did not allocate any cargoes to Orlen or its intermediaries because it had not been paid. PDVSA requires 50% of a cargo prepayment before assigning a loading window.

Last November, Orlen chartered three supertankers to Venezuela to load 5.7 million barrels of Merey 16 heavy crude, but they either left empty or were chartered by other customers after languishing in Venezuelan waters for months, sources familiar with the matter said. (Reporting by Marek Strzelecki, Marianna Parraga, and Anna Koper; Additional reporing by Yousef Saba and Maya Gebeily; Editing by Mark Potter)