Search.columns

Note:

The content in this help topic pertains to SuiteScript 2.0.

Property Description

Columns to return for this search as an array of search.Column objects or a string array of column names.

You set this value with an array of search.Column objects or a single search.Column to overwrite any prior return columns for the search. Use null to set an empty array and remove any existing columns on this search.

Type

search.Column[] | string[]

Supported Script Types

Client and server scripts

For more information, see SuiteScript 2.x Script Types.

Module

N/search Module

Since

2015.2

Errors

Error Code

Thrown If

SSS_INVALID_SRCH_COLUMN

The value passed in was not a string or search.Column Object

Syntax
Important:

The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/search Module Script Samples.

          //Add additional code
...
function createSearch() {
            var mySalesOrderSearch = search.create({
                type: search.Type.SALES_ORDER,
                columns: ['entity', 'subsidiary', 'name', 'currency'],
            });
...
//Add additional code 

        

Related Topics

search.Search
N/search Module
SuiteScript 2.x Modules
SuiteScript 2.x

General Notices