Help with Filtering Customers by Subsidiary in Sui...
# general
b
Help with Filtering Customers by Subsidiary in SuiteSQL Hi everyone, I'm trying to filter customers by subsidiary in SuiteSQL, but I haven't been able to get the correct query. I used the following query:
Copy code
SELECT * FROM item i WHERE i.subsidiary LIKE '%4%' FETCH FIRST 5 ROWS ONLY;
However, it doesn’t seem to work as expected. Could anyone clarify what data type
subsidiary
is? Also, what would be the correct query to achieve this filtering? Thanks!
j
Subsidiary is a list field so by default you see an integer instead of the name you will see the internal ID. It is not text so you would just use the integer 4.
i.subsidiary = 4
If you want to see the text value of the list field you can use BUILTIN.DF(subsidiary) instead. You can use that in both results and filters