Has anyone written a search for finding "Buildable...
# suitescript
c
Has anyone written a search for finding "Buildable" Work Orders? The statusRef field on Work Orders isn't exposed and it doesn't appear you can expose it. The one suiteanswers article reference I could find no longer exists (it claimed to expose the buildable field).
t
Not sure if this is helpful, but... In SuiteQL, on the Transaction table, there's a "committed" column that maps to the "Buildable" field label in the UI. It might be worth looking at.
c
I'll check to see if there's any correlation then thanks
t
np Good luck!
j
I know when I looked at something similar I used the orderstatus field and mapped out the values. I think released and in process would be classified as buildable. Planned : "A" Released : "B" In Process : "D" Closed : "H" Built : "G"
c
I thought so as well, but the list of buildable work orders on the "build work orders" native netsuite page are not the same results as work orders w/ those 2 statuses.
so im trying to see the difference and the main difference is the statusRef property says its buildable but its not exposed in any way
s
you're not making me excited about a workorder related project I'm about to embark on 🙂
c
The work order itself is easy. This is just a client request im trying to work with and it just may not be possible as written.
There's this status ref field that I need that lets me know. Its not exposed.
t
It's odd that it isn't exposed, and getting to it via SuiteQL is tricky, too. Here's a query that will return all work orders that are "Pending Build."
Copy code
SELECT
	ID,
	TranID,
	Status,
	BUILTIN.DF( Status ) AS StatusName,
	Entity,
	BUILTIN.DF( Entity ) AS EntityName
FROM
	Transaction
WHERE
	Type = 'WorkOrd'
	AND ( BUILTIN.DF( Status ) = 'Work Order : Pending Build' )
c
I believe there's another way to get it. The WIP box on Work Orders drives the rest of it so if that box is NOT checked, it will show up in the Build Work Orders table
You def can't get to that in Saved Searches as far as I can tell unless a formula field will expose it
t
I think you're right. The interesting thing about it is that the underlying status value seems to "B" (or specifically "WorkOrd:B") regardless of whether the work order is released or pending build. If you use that BUILTIN.DF function, it seems to take something else into account (maybe "WIP" - the column name for which is "IsWip") to return a sub-status of either "Work Order : Released" or "Work Order : Pending Build."
c
I'm gonna roll w/ In Process/Planned/Released and no WIP
d
We rely heavily on the WO process and build thousands at a time in waves using a map/reduce script. I use status = Work Order: Released and formula(numeric) "CASE WHEN {buildable} = {quantity} THEN 1 ELSE 0 END" is not 0.
💯 1