Context : Magento CE2.2.0
I have to set up the following tax rules:

customer address in   | B2C     |  B2B
France                | VAT 20% | VAT 20%
Euro zone             | VAT 20% | VAT 00%
Rest of the world     | VAT 00% | VAT 00%

The only way I could think of in Magento 2.2 (without messing up with modules) is to - set tax calculation on customer billing address - upload the tax zones in csv

I set up the csv with the required lines:

  • one line for france
  • 2 lines for euro zone (B2C, B2B)
  • one line for any other country

Total is roughtly 270 lines ; Only the first 200 manage to be uploaded in magento. I swapped lines in my csv: confirm that only the first 200 lines are processed.

My questions:

  • how to make magento handle more than 200 tax zones?
  • This limit feels arbitrary: is it set as a parameter somewhere?
  • is there a way to wildcard the country (I could have only 1 line for "rest of the world)

All suggestions are welcome

EDIT/SOLVED: I had Puerto Rico 'PR' in my csv file. It matters not the position of this line, it jammed the import after 200 lines.
Once removed, the import is processed beyond the 200th line.


1 Answer 1


Do not use "PR" country code: it is no longer legit since USA annexed it in the late 2017.

  • This can't surely be true? The US annexed Puerto Rico in 1898, and it has remained a territory within the USA ever since. It is fully recognized by the international community (including the US) as a territory, and its current ISO 3166-1 Alpha-2 Country Code (PR) has been official since 1974. According to ISO themself, the PR code has not been redacted and is still in use!
    – Xyz
    Aug 22, 2019 at 10:46
  • I am not in politics, tell that to magento and USA officials, but when you use the code 'PR', your import is rejected. github.com/magento/magento2/issues/21366#issuecomment-465653486 Aug 22, 2019 at 12:09
  • Actually, it does not fail due to politics, but due to a bug in Magento. The PR country code was applied for by the US itself. Only independent countries can apply for country codes for outlying islands and territories, and the US did this for Puerto Ricon in 1974. There is no drama in that. The fault lies entirely with Magento. In fact, the PR country code is not the only one they are missing in the directory_country database table. They also har lacking South Sudan (SS), Bonaire, Sint Eustatius and Saba (BQ), Sint Maarten (SX), Curaçao (CW) and Aruba (AW).
    – Xyz
    Aug 23, 2019 at 11:25
  • So the exact same error happens if you try import tax codes for any of these areas. For South Sudan, this is troublesome, because it is a fully recognized and sovereign country. For the BQ, SX, CW and AW country codes, it is also troublesome, as they are all oversea countries and territories (OCT) of varying degree of the European Union, but not part of the EU tax zone itself. To complicate things further, they don't have zip or postal codes, so in effect, it is impossible to set up shipping and tax rules in Magento for these islands.
    – Xyz
    Aug 23, 2019 at 11:39
  • On another hand, several insularies regions of France have their distinct country ISO code (Guadeloupe, Martinique...). It would really help if Magento show us the actual list they consider. Aug 23, 2019 at 12:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.