How to update record in NetSuite using Suite script

var theRecord=record.load({
  type: record.Type.SALES_ORDER,
  id:12344,   
  isDynamic: false, 
  defaultValues: null
}); 
log.debug("old value",theRecord.getValue({fieldId:'trandate'}));
theRecord.setValue({
 fieldId : 'trandate',
 value :invoiceDate
});
log.debug("New value",theRecord.getValue({fieldId:'trandate'}));
theRecord.save (); 

How to use joins in search columns and filters in Suitescripts

var formula = "{field1}-{field2}";
search.create({ 
type: search.Type.TRANSACTION, 
title: 'Title of the search', 
 id: 'search_id', 
 columns: [ 
  {name: 'trandate'},
  {name: 'entity',join: 'appliedToTransaction'} 
 ],
filters: [
 {name: 'type', operator: 'anyof', values: ['Mention Transaction type here (sales order, purchase order, etc)'] },
 {name: 'type',  join: 'appliedToTransaction',operator: 'anyof', values: ['CustInvc']},
 {name: 'formulanumeric',operator: 'GREATERTHAN',values: 0,formula: formula}
]
});       

Introduce Yourself

I am a software engineer. Currently working as an application developer in USA based company. I have 4 years of work experience in the Industry in web development. I have developed websites, newsletters using WordPress. I have built web interfaces using PHP, HTML, Javascript, DataTables, AJAX, and MySQL. I have written scripts to integrate third party applications with Salesforce and Net Suite using REST API. I enjoy coding. I have good problem solving and good analytical skills.

Design a site like this with WordPress.com
Get started