Powerbi OR逻辑的嵌套IF函数
我似乎看不出下面的嵌套IF公式有什么不对 互联网搜索Powerbi OR逻辑的嵌套IF函数,powerbi,dax,Powerbi,Dax,我似乎看不出下面的嵌套IF公式有什么不对 互联网搜索 IF ( SEARCH ( "compontentdissociation", 'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS], 1, 1000 ) <> 1000, 18, IF ( SEARCH ( "dislocation
IF (
SEARCH (
"compontentdissociation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000,
18,
IF (
SEARCH (
"dislocation subluxation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000,
18,
IF (
SEARCH (
"Prosthesis Dislocation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000,
18
)
)
)
IF(
搜寻(
“成分关联”,
“njrew_k_prmry_bicon_outcm”[INDREV_Summary Revision Reasures],
1.
1000
) 1000,
18,
如果(
搜寻(
“脱位半脱位”,
“njrew_k_prmry_bicon_outcm”[INDREV_Summary Revision Reasures],
1.
1000
) 1000,
18,
如果(
搜寻(
“假体脱位”,
“njrew_k_prmry_bicon_outcm”[INDREV_Summary Revision Reasures],
1.
1000
) 1000,
18
)
)
)
使用or和3个条件的能力您可以像这样使用or运算符,而不需要嵌套:
IF (
SEARCH (
"compontentdissociation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000
|| SEARCH (
"dislocation subluxation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000
|| SEARCH (
"Prosthesis Dislocation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000,
18
)
SWITCH (
TRUE (),
SEARCH (
"compontentdissociation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18,
SEARCH (
"dislocation subluxation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18,
SEARCH (
"Prosthesis Dislocation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18
)
您可以像这样使用OR运算符
|
,而不需要嵌套:
IF (
SEARCH (
"compontentdissociation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000
|| SEARCH (
"dislocation subluxation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000
|| SEARCH (
"Prosthesis Dislocation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000,
18
)
SWITCH (
TRUE (),
SEARCH (
"compontentdissociation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18,
SEARCH (
"dislocation subluxation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18,
SEARCH (
"Prosthesis Dislocation",
'njrew_k_prmry_bicon_outcm'[INDREV_SUMMARYREVISIONREASONS],
1,
1000
) <> 1000, 18
)
亚历克西斯。非常感谢您对这个问题的有益反馈。亚历克西斯。非常感谢您对这个问题的有益反馈。