POWER BI/함수

Switch

Knowing Me 2024. 10. 16. 04:18

1. 정의: 조건이 여러 개일 때 각 조건의 값을 비교하는 함수이다. IF 함수 대신 사용할 수 있다. 

 

2. 공식

 

  • Expression: The expression that is evaluated.
  • Value: The values that are compared against the expression.
  • Result: The results that are returned if the expression matches the corresponding value.
  • Else: An optional result that is returned if none of the values match the expression.

 

3. 예시

 

 

 

*출처:

Mastering SWITCH in DAX for Power BI: A Comprehensive Guide (2024), Datacamp, available at https://www.datacamp.com/tutorial/switch-in-dax-for-power-bi

'POWER BI > 함수' 카테고리의 다른 글

Vstack vs. Hstack  (0) 2024.10.20
SUMMARIZE  (0) 2024.04.06
FILTER  (0) 2024.04.06
SUMMARIZECOLUMNS  (0) 2024.04.06
SUMX  (0) 2024.03.23