hi everyone, i want to get all the matrix option o...
# suiteql
b
hi everyone, i want to get all the matrix option of an item using suiteql does anyone know how can i fetch that using suiteql?
n
Meaning you input that parent matrix item as a param and get all of the children?
Copy code
SELECT
	Item.ID,
	Item.ItemID,
	Item.FullName,
	Item.Description
FROM
	Item
WHERE
	( Item.Parent = PARENT_ITEM_ID )
	AND ( Item.IsInactive = 'F' )
b
in my account i have 3 custom fields (size,color,platform) that has enabled matrix option which means it can be used to create matrix option i have used this query to get the customfield of items where its fieldvaluetype is Multiple Select it return about 12 custom field including the list where matrix option is disabled i only wants to get that 3 custom fields where matrixoption is enabled
Copy code
select * from customfield where fieldtype='ITEM' AND fieldvaluetype='Multiple Select'
n
Can't you just explicitly reference those 3 columns? Or you want to to detect new columns that may be added?
So you want all fields where
itemmatrix = 'T'
?
b
actually for each item not all of these customfield are enabled so it’s hard to check which fields are for matrix option so i tried to get all the custom fields where matrixoption is enabled
n
Hmmm I would need to think on this because
itemmatrix
seems to not be available in SuiteQL
b
yes only this data is returned for the custom field
In theory you can do * onto a item get all of the columns and then extract the ones that start with matrixoption but thats pretty heavy lifting
b
Yes this will be very complex