Basic Syntax

Documentation article about Basic Syntax

·1 min read·5 views·NetSuite 2026.1·View Oracle Docs

Basic Syntax

Basic Syntax

To understand the syntax of a simple search, we'll use the sample below:

{

"record": "supportcase",

"filters": ["internalid","anyof","${event.supportcase || 0}"],

"map": {

"id": "internalid",

"label": "casenumber"

} }

The record property sets the search type to run or the record type to search for. In the sample above, we're searching for Case records. You can find the ID of the record or search type using the NetSuite record browser. For more information see, Working with the SuiteScript Records Browser.

The filters property sets the search criteria.

The map property sets what results will be returned. In this example, you'll get back an object with two properties: id and label.

Frequently Asked Questions (4)

What are the prerequisites for using SuiteScript to perform searches on NetSuite records?
To perform searches using SuiteScript, you need access to the SuiteScript Records Browser to ensure you're using supported record IDs and fields. Additionally, make sure you are referencing IDs listed in the NetSuite Help Center, as unsupported IDs might break your script if they change.
Can I modify all record fields via SuiteScript?
No, not all fields can be modified via SuiteScript. Some fields are read-only and can only be retrieved. Generally, if a field can be set in the NetSuite UI, it can be set using SuiteScript.
How does the 'map' property work in a SuiteScript search object?
The 'map' property in a SuiteScript search object defines the structure of the results returned. It will map the resulting data fields to specified properties, like 'id' and 'label' in the provided sample code, to include them in the returned search results.
What should I be cautious of when referencing record IDs in SuiteScript?
When using record IDs in SuiteScript, ensure they are supported by checking the SuiteScript Records Browser, as unsupported or undocumented IDs may change, causing your script to break.

Weekly Update History (1)

Field Service Managementupdated

Updated the Nested Searches topic to include an example.

View Oracle Docs
Source: Basic Syntax Oracle NetSuite Help Center. This article was generated from official Oracle documentation and enriched with additional context and best practices.

Was this article helpful?

More in Field Service Management

View all Field Service Management articles →

Also from NetSuite 2026.1

View all NetSuite 2026.1 changes →