I have the following formula but it is not displaying anything. Any ideas?
if {JCCONTM0_DAT.WAREASON2} = "MATEK" or {JCCONTM0_DAT.WAREASON2} = "MATDK" then
if {JMEMBRM0_DAT.AACOUNTY} = "33" then 'R'
else if {JMEMBRM0_DAT.AACOUNTY} = "36" then 'S'
(
(
if {JCCONTM0_DAT.WAREASON2} = "MATEK" or {JCCONTM0_DAT.WAREASON2} = "MATDK" then
(
if {JMEMBRM0_DAT.AACOUNTY} = "33" then 'R'
else if {JMEMBRM0_DAT.AACOUNTY} = "36" then 'S'
)
// might put an else here for testing
)
// might put an else here for testing
)
Try laying the fields on your report in the detail section to make sure they do, in fact, display as "MATEK", "MATDK", "33", "36", etc. It will also let you see if you have any nulls to handle.
You could also try something like:
if (isnull({JCCONTM0_DAT.WAREASON2}) or
trim({JCCONTM0_DAT.WAREASON2}) = "") then
"No Reason Specified" else
if {JCCONTM0_DAT.WAREASON2} in ["MATEK", "MATDK"] then
(if (isnull({JMEMBRM0_DAT.AACOUNTY}) or
trim({JMEMBRM0_DAT.AACOUNTY}) = "") then
"No Result" else
if {JMEMBRM0_DAT.AACOUNTY} = "33" then 'R' else
if {JMEMBRM0_DAT.AACOUNTY} = "36" then 'S' else
"Other Result") else
"Other Reason"
I pasted your statement into the formula editor and replaced your fields and values such that I knew there would be records and it worked fine. So your phrasing is ok (presuming that {JMEMBRM0_DAT.AACOUNTY} is character data not numeric) - it's something probably very simple like putting the field in the wrong report section or maybe you are writing a question for which there are no records.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.