WARSAW - A Polish ban on imports of Ukrainian grain and other food will also apply to the transit of these products through the country, the development and technology minister said on Sunday.

Poland and Hungary said on Saturday that they had decided to ban imports from neighbouring Ukraine to protect the local agricultural sector after a flood of supply depressed prices across the region. The Polish ban came into effect on Saturday evening.

"The ban is full, including the ban on transit through Poland," Waldemar Buda wrote on Twitter, adding that talks would be held with the Ukrainian side to create a system that ensures goods only pass through Poland and do not end up on the local market.

Ukraine's ministry of agrarian policy and food said on Saturday that the Polish ban contradicted existing bilateral agreements on exports, and called for talks to settle the issue.

After Russia's invasion blocked some Black Sea ports, large quantities of Ukrainian grain, which is cheaper than that produced in the European Union, ended up staying in Central European states due to logistical bottlenecks, hitting prices and sales for local farmers.

The issue has created a political problem for Poland's ruling Law and Justice (PiS) party in an election year as it has angered people in rural areas where support for the party is usually high.

(Reporting by Alan Charlish; Editing by Sharon Singleton)