RE: Accessing system default packages in suitescript

First post! I’m trying to access the system default shipping packages in a suitescript. Not sure what the “correct” name for these records is but they are located in Setup > Accounting > Shipping > Packages in the UI, and they can be associated to inventory item records and they determine the default configuration for packages in Item Fulfillment records.

I can’t for the life of me figure out how to access this list anywhere except in the UI. Saved searches don’t be able to access them, and I’m not seeing any mention of them in the netsuite schema/record browser.

The only relevant thing I’ve seen is “Shipment packages”, but those seem to be specific to individual IF records and contain package/contents description, reference number, etc. The packages I’m looking for should be much more generic, with just length, height, width, maximum number of items, etc.

Any insight from anyone here?

patrickfrench Rookie Asked on June 30, 2020 in SuiteScript.
Add Comment
1 Answers
Best answer

The normal api to use to access configuration is N/config. It does not support shipping preferences, so you probably can’t get those preferences via suitescript.

Advanced Answered on June 30, 2020.

Thanks for the answer, battk. Let me ask another way: is there a way to get this information from the item record in some way? accessing the shippackage field just gives me the internal ID of the package, which considering the circumstances is totally useless. If I could just get the dimensional data about height/width/length, I wouldn’t actually need the record itself. I’ve gotta believe it’s possible to get that somehow???

on June 30, 2020.

SuiteAnalytics Workbook is probably your best chance since the traditional SuiteBuilder or Saved Search options dont work.

I personally recommend making the dataset in the ui first, then using N/query to load the workbook so that you can get and use its SuiteQL. More technical would be to load the query to recreate its structure in code.

on June 30, 2020.

Genius. I’m going to take a stab at this, I’ll report back if it works!

on June 30, 2020.

battk, you saved me! Creating a dataset in SuiteAnalytics and loading it up in suitescript worked like a charm. I tried using the “query.runSuiteQL”  method here but couldn’t get it to return non-null values even when using the fieldIds from the resultSet from the working dataset… not sure what that’s about, but it hardly matters beyond my own sense of aesthetics so for all intents and purposes I’m unblocked.

Much appreciated, thanks again! Definitely going to keep this one in my back pocket when I run into these “netsuite doesn’t want to give me access to the data” problems in the future!

on June 30, 2020.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.