title: Simple search for Netsuite Suitetalk API and PHP Toolkit
body: <p>I'm trying to make a simple search with Netsuite Suitetalk API and the latest PHP Toolkit version.</p>
  
  <p>Here is my code:</p>
  
  <pre><code>$service = new NetSuiteService();
  $service-&gt;setSearchPreferences(false, 20);
  
  $typeSearchField = new SearchStringField();
  $typeSearchField-&gt;operator = SearchStringFieldOperator::is;
  $typeSearchField-&gt;searchValue = "SalesOrder";
  
  $search = new TransactionSearchBasic();
  $search-&gt;recordType = $typeSearchField;
  
  $request = new SearchRequest();
  $request-&gt;searchRecord = $search;
  
  $searchResponse = $service-&gt;search($request);
  </code></pre>
  
  <p>However, this request returns all records from Netsuite, not just the SalesOrders. Any idea what I'm doing wrong?</p>
  
  <p><strong>Update:</strong>
  here is the working version, with the help of eliseobeltran. I had to change also $search->recordType with $search->type</p>
  
  <pre><code>$service = new NetSuiteService();
  $service-&gt;setSearchPreferences(false, 20);
  
  $SearchEnumMultiSelectField = new SearchEnumMultiSelectField(); //set up multiselect field to which IDs will be put
  $SearchEnumMultiSelectField-&gt;searchValue = Array('_salesOrder'); //put IDs of transactions to search for as a search value
  $SearchEnumMultiSelectField-&gt;operator = 'anyOf'; //set operator according to which search will be executed. Values are anyOf/noneOf
  
  $search = new TransactionSearchBasic();
  $search-&gt;type = $SearchEnumMultiSelectField;
  
  $request = new SearchRequest();
  $request-&gt;searchRecord = $search;
  
  $searchResponse = $service-&gt;search($request);
  </code></pre>