Chidi Okwudire IT Professional. ERP Enthusiast. NetSuite Certified (Administrator, SuiteCloud Developer II, and ERP Consultant). Celigo Certified (Level 4+). Passionate About Empowerment Through Knowledge Sharing. Always Eager to Learn.

Tip: Learn How to Query NetSuite’s State/Country List

52 sec read

NetSuite maintains a list of countries and states/provinces where applicable. These tables can be queried via SuiteQL as well-documented in this article [I]Tim Dietrich (July 1, 2021). NetSuite: Use SuiteQL to Get Lists of States and Countries. Available at: https://timdietrich.me/blog/netsuite-suiteql-states-countries/ [Accessed: November 28, 2022].

However, when executing a State query from a custom role recently, I got the following error:

SSS_SEARCH_ERROR_OCCURRED - Search error occurred: Record 'State' was not found.

This was confusing as I was sure that the ‘State’ table exists in the Records Catalog and I was able to successfully query it using a SuiteQL Query Tool [II]Tim Dietrich. SuiteQL Query Tool. Available at: https://timdietrich.me/netsuite-suitescripts/suiteql-query-tool/ [Accessed: November 28, 2022] [III]Marty Zigman (March 13, 2021). NetSuite SQL Query Tool. Available at: https://blog.prolecto.com/2021/03/13/netsuite-sql-query-tool/ [Accessed: November 28, 2022].

After some poking around, I learned that the error was due to a missing permission! The required permission to access this table (and perhaps others?) is Setup >> Set Up Company (View or higher).

Refer to this article [IV]Tim Dietrich (May 2, 2022). NetSuite: SuiteQL Tables & Permissions Reference. Available at: https://timdietrich.me/blog/netsuite-suiteql-tables-permissions-reference/ [Accessed: November 28, 2022] for a list of permissions required for various SuiteQL tables.


I commend Tim Dietrich’s (a.k.a. the “SuiteQL Guy”) dedication to making SuiteQL more accessible to the NetSuite community. Check out his blog here. If you’re not yet started exploring/using SuiteQL, you’re missing out.

NetSuite Insights is on a mission to raise the standards around NetSuite practices, one insight at a time. If that resonates with you, check out how you can become an author/collaborator here.

Also, consider subscribing to our no-nonsense email list to get these insights delivered to your inbox as soon as they’re published. Sometimes, ignorance is a choice. Choose wisely!

Further Reading[+]

Chidi Okwudire IT Professional. ERP Enthusiast. NetSuite Certified (Administrator, SuiteCloud Developer II, and ERP Consultant). Celigo Certified (Level 4+). Passionate About Empowerment Through Knowledge Sharing. Always Eager to Learn.

2 Replies to “Tip: Learn How to Query NetSuite’s State/Country List”

  1. That one has bitten me as well! I had to use the UI to back into the true error years ago. Thanks for posting this to help others!

Leave a Reply

Your email address will not be published. Required fields are marked *

You deserve to know as soon as we share a new NetSuite Insight.
We won't disturb you with anything else or share/sell your data.