Inforiver
EDITable
EDITable
  • Introduction to EDITable
    • Why EDITable?
    • Supported Database Connections
  • Get Started
    • EDITable Pre-requisites
      • Admin consent for EDITable's Entra ID
        • Basic consent
        • Full admin consent
    • Install EDITable
    • Add EDITable visual
  • Getting Data into EDITable
    • Connect to Data
      • Get data
      • Assign fields
      • Configuration Steps
        • Configure source
        • Configure Columns
        • Configure Type 2 SCDs (Optional)
    • Create a Table
      • Create From Scratch
      • Use Existing Table
      • Import Data
  • Working with EDITable
    • EDITable interface
    • Manage Columns
      • General
      • Constraints
      • Lookup and Relation
      • Display
      • Import/Export Configuration
      • Add Database Column
      • Insert Column
    • Column Access Control
    • Row Identification
    • Table Operations (Insert/Update/Delete)
      • Edit data
      • Bulk Edit
      • Find and Replace
      • Insert rows
      • Insert Column
      • Import rows
      • Delete rows
      • Duplicate rows
      • Copy rows
      • Preview Changes
      • Reset Changes
    • Explore data
      • Search and filter
      • Sort and reorder
      • Show/Hide columns
      • Pin columns
      • Group Rows By
      • Summarize Column
    • Basic formatting
    • Conditional Formatting
  • Row Access Control
  • Approval Workflow
    • Review Changes - Workflow process
  • Type 2 SCDs
    • Configuring Type 2 SCDs in EDITable
  • Audit logs
  • Webhook
  • Display Settings
  • Commenting and Collaboration
    • Assign users & task status
    • View all comments & track changes
    • Comment Settings
  • Admin Portal & EDITable Console
    • Tables
    • Transaction Logs
    • Insights (Metrics)
    • Utility
      • Download Report
      • Pipeline
        • Power BI & EDITable deployment pipelines
        • Deployment in different destinations
        • Trigger deployment pipeline from external applications
        • Logs & other pipeline options
    • Manage Profile
    • Admin Portal
      • User Management
      • Settings
        • General Settings
        • Writeback Settings
          • Settings
          • EDITable managed DB
        • API token
    • Onboarding Actions
  • Formula and Functions
    • Conditional statements
      • IF
      • IFNA
      • SWITCH
    • Logical functions
      • AND
      • IN
      • ISBLANK
      • ISEMPTY
      • ISNUMBER
      • NOT
      • OR
      • XOR
    • Math functions
      • ABS
      • AVERAGE
      • AVERAGEIF
      • AVERAGEEXNEG
      • AVERAGEEXZERO
      • AVERAGEEXZERONEG
      • CEILING
      • COUNT
      • COUNTIF
      • DIVIDE
      • EVEN
      • EXP
      • FLOOR
      • LOG
      • MAX
      • MIN
      • PCT
      • POWER
    • Text formatting functions
    • Date functions
      • DATE
      • DATE.FORMAT
    • Other operators
  • Keyboard Shortcuts
  • Release Notes
    • EDITable - v1.7.5
    • EDITable - v1.7
    • EDITable - v1.6.5
    • EDITable - v1.6
Powered by GitBook
On this page
  • Syntax
  • Arguments
  • Return value
  • Example
  • Excel equivalent
  1. Formula and Functions
  2. Conditional statements

SWITCH

The SWITCH function evaluates an expression against a list of values and returns the result corresponding to the first matching value. If there is no match, an optional default value is returned.

Syntax

switch( expression, val1, res1, val2, res2, ... val_n, res_n, default )

Arguments

exp – The statement to be evaluated

val1, val2, … val_n – The list of values to be compared against the expression

res1, res2, … res_n – The result to be returned in case of a match

default – The default value to be returned if the expression does not match with any of the values in the argument list. This is an optional argument.

Return value

Result when the expression matches with value, default in case there was no match.

Example

SWITCH(Region, "West", 25, "East",30, 50)

Will return 25 if the region is West, 30 if the region is East and 50 for all the other regions

Excel equivalent

PreviousIFNANextLogical functions

Last updated 6 months ago

SWITCH