CASE WHEN {subsidiary.parent#display} == {subsidia...
# ask-stanley-ai
w
CASE WHEN {subsidiary.parent#display} == {subsidiary#display} THEN 1 ELSE 0 END ehy is this not correct formula in analytics book
c
AI generated answer (using internal Slack threads):
The formula
CASE WHEN {subsidiary.parent#display} == {subsidiary#display} THEN 1 ELSE 0 END
is not correct in the analytics workbook because the syntax is not correct for NetSuite's formula fields. In NetSuite, the correct syntax for a CASE WHEN statement is
CASE WHEN {field} = 'value' THEN 'result' ELSE 'alternative result' END
. The
==
operator is not recognized in NetSuite formulas, you should use
=
instead. Also, the
#display
is not a valid field reference in NetSuite. If you want to compare the display value of a field, you should use the field name directly. So, the correct formula should be something like
CASE WHEN {subsidiary.parent} = {subsidiary} THEN 1 ELSE 0 END
. Please note that this formula will compare the internal IDs of the parent subsidiary and the subsidiary. If you want to compare the names, you might need to use a join to get the name of the parent subsidiary. ****** Disclaimer: This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes. ******
Slack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.833496153
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.810302615
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.807006836
Please provide your feedback on this answer.