Discussions
Stay up-to-date with the latest news from NetSuite. You’ll be in the know about how to connect with peers and take your business to new heights at our virtual, in-person, on demand events, and much more.
Now is the time to ask your NetSuite-savvy friends and colleagues to join the NetSuite Support Community! Refer now! Click here to watch and learn more!
Stay in the Know
Be sure you're subscribed to NetSuite communication to stay in the know about monthly happenings, updates and announcements. Subscribe
Be sure you're subscribed to NetSuite communication to stay in the know about monthly happenings, updates and announcements. Subscribe
runtime.executionContext and Map/Reduce
I want to be able to detect where the script triggered from so that I can ignore some script parameters. I am using runtime.executionContext which according to the doc returns a runtime.ContextType that represents what triggered the current script. When I log out the runtime.executionContext in my Map/Reduce, i get "MAPREDUCE". This isn't even in the runtime.ContextType object (see below for object details). Is there an issue with this currently? Is there something else I should be using to detect if my map/reduce was triggered from the user interface?
runtime.ContextType log:
{ "USER_INTERFACE":"USERINTERFACE", "WEBSERVICES":"WEBSERVICES", "WEBSTORE":"WEBSTORE", "PORTLET":"PORTLET", "SCHEDULED":"SCHEDULED", "SUITELET":"SUITELET", "CSV_IMPORT":"CSVIMPORT", "CUSTOM_MASSUPDATE":"CUSTOMMASSUPDATE", "WORKFLOW":"WORKFLOW", "USEREVENT":"USEREVENT", "ACTION":"ACTION", "DEBUGGER":"DEBUGGER", "CLIENT":"CLIENT", "BUNDLE_INSTALLATION":"BUNDLE_INSTALLATION", "RESTLET":"RESTLET", "WEBAPPLICATION":"WEBAPPLICATION", "PAYMENTGATEWAY":"PAYMENTGATEWAY", "CONSOLRATEADJUSTOR":"CONSOLRATEADJUSTOR", "PROMOTIONS":"PROMOTIONS", "CUSTOMGLLINES":"CUSTOMGLLINES", "TAX_CALCULATION":"TAXCALCULATION", "SHIPPING_PARTNERS":"SHIPPINGPARTNERS", "EMAIL_CAPTURE":"EMAILCAPTURE" } 0