You need to make sure that the values you are inserting, are created in Salesforce to avoid this and other errors. Also ensure that there is a corresponding Billing/Shipping State if there is a value on Billing/Shipping Country or set the Billing/Shipping State to blank.
While making changes to User setting, the same issue can possibly occur if the 'State/Province' and 'Country fields' have invalid values in user's personal settings. This can be changed by the user by following the click path:
My Settings | Personal | Personal Information (Address section)
To check if the State and Country/Territory is valid or active in the org, follow these steps:
Classic: Setup | Data Management | State and Country/Territory Picklists
Lightning: Gear Icon | Setup | Data | State and Country/Territory Picklists
1.Under the first step, click ‘Configure states and countries'
2.Make sure that the Country is currently active
3.Click on Edit at the left side of the country to check the State/Province under the country and check if Active
(Optional)
4.If you cannot find the Country or the State, click the ‘New Countries/Territories’ or ‘New State’ button to add
5.Fill in the required fields, Check Active then Save.
Note: If the error is on Opportunity save, check the related Account record and update the Country/State field as the Opportunity object itself does not have a standard State/Country.
If the issue persists, please contact Salesforce Technical Support.
000387137

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.