How to Change Values in a Column in Power BI

Cody Schneider••6 min read

Need to modify values within a column in Power BI? Whether you're fixing typos, standardizing categories, or bucketing numbers, changing data is a fundamental step in building any useful report. This guide will walk you through the most effective ways to change column values, using both the user-friendly Power Query Editor and the powerful DAX language.

GraphedGraphed

Build AI Agents for Marketing

Build virtual employees that run your go to market. Connect your data sources, deploy autonomous agents, and grow your company.

Watch Graphed demo video

The Best Place for Data Transformation: Power Query Editor

Before jumping into the "how," it's important to know the "where." For most data cleaning and transformation tasks - like changing values in a column - the Power Query Editor is your best friend. Why? Because changes made in Power Query happen before your data is loaded into the Power BI data model. This creates a cleaner, more efficient, and easier-to-manage dataset for your reports.

These transformations become repeatable steps in your data refresh process. Every time you refresh your data, Power Query automatically applies the same cleaning and replacement logic without any extra work. You can access it by clicking the Transform Data button on the Home tab in Power BI Desktop.

Now, let's look at the three primary methods you can use within the Power Query Editor.

Free PDF · the crash course

AI Agents for Marketing Crash Course

Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.

Method 1: The "Replace Values" Feature (The Quick Fix)

This is the simplest and most direct method. It's perfect for situations where you need to perform a straightforward find-and-replace action.

When to use this method:

  • Fixing spelling mistakes (e.g., changing "Untied States" to "United States").
  • Standardizing abbreviations (e.g., changing "CA" to "California").
  • Replacing nulls or placeholder values (e.g., changing "N/A" to "Not Applicable").

Step-by-Step Instructions:

  1. With Power Query Editor open, select the column where you want to replace values.
  2. Navigate to the Transform tab in the ribbon.
  3. Click the Replace Values button.
  4. A dialog box will appear. In the "Value to Find" field, enter the text you want to replace.
  5. In the "Replace With" field, enter a new value. Be careful: if you leave this blank, it will replace your target value with nothing (i.e., remove it).
  6. Click OK.

For example, imagine a Country column with inconsistent data entries like "USA," "U.S.," and "United States." You could use "Replace Values" twice to standardize them all to "United States." It's fast, simple, and tracks each replacement as a step in the "Applied Steps" pane.

Method 2: Creating a Conditional Column (For "If-Then" Logic)

Sometimes a simple replacement isn't enough. You might need to change or categorize values based on a set of rules or conditions. The Conditional Column feature provides a wizard-like interface to handle this without writing any code.

This method doesn't change the original column but instead creates a new column with your desired values. This is often better, as it preserves your original data for reference.

When to use this method:

  • Grouping numeric data into categories (e.g., categorizing sales amounts as "Small," "Medium," or "Large").
  • Creating priority levels based on text values (e.g., if a ticket status is "In Progress" or "New," set the new column value to "Active").
  • Flagging rows that meet certain criteria (e.g., if _Order Date_ is within the last 7 days, flag it as "Recent").

Step-by-Step Instructions:

  1. In Power Query Editor, go to the Add Column tab.
  2. Click on Conditional Column. This opens the editor.
  3. In the "New column name" field, give your new column a descriptive name (e.g., "Sales Category").
  4. Now, build your "if-then" statement using the UI:
  5. Click Add Clause to create more "else if" conditions. For example, you could add a second rule: _if "Transaction Amount" is greater than 100, then output "Medium Sale"_.
  6. Finally, in the "Else" field at the bottom, specify the default value if none of your conditions are met (e.g., "Small Sale").
  7. Click OK. Power BI generates a new column with your categorized values.
GraphedGraphed

Build AI Agents for Marketing

Build virtual employees that run your go to market. Connect your data sources, deploy autonomous agents, and grow your company.

Watch Graphed demo video

Method 3: Writing a Custom Column with M Language (For Maximum Flexibility)

When the "Conditional Column" feature isn't powerful enough for your needs - especially when your logic involves multiple columns - you can write your own logic using M, Power Query's formula language.

When to use this method:

  • You need complex logic that references more than one column (e.g., if [Region] = "West" AND [Revenue] > 10000).
  • You need to perform text manipulation, like concatenating strings or extracting parts of a value, as part of your condition.
  • Your transformation involves mathematical formulas or functions not available in the simple UI.

Step-by-Step Instructions:

  1. In Power Query, go to the Add Column tab and click Custom Column.
  2. Give your new column a name.
  3. In the "Custom column formula" box, write your if statement using M syntax.

The basic structure is: if [ColumnName] <operator> value then <output_if_true> else <output_if_false>

For a basic example that replicates a conditional column:

if [Satisfaction Score] >= 4 then "Happy" else "Needs Attention"

For a more advanced example that combines two columns:

if [Deal Status] = "Closed-Won" and [Contract Value] > 50000 then "Key Account" else "Standard Account"

The formula editor helps you by suggesting column names as you type. Once you've entered your formula, click OK to create the column.

An Alternative Approach: Using DAX for Calculated Columns

You can also create new columns with substitute values using DAX (Data Analysis Expressions) directly in the report view. This is fundamentally different from Power Query.

Power Query vs. DAX:

  • Power Query transformations are done statically during data refresh. The new values are stored in the data model. Use this for data cleaning and preparation.
  • DAX calculated columns are calculated dynamically and can re-evaluate based on report context (though usually they are calculated once at data load). They are part of the report's logic, not the initial data prep. Use this when the calculation needs to know about other tables or complex measures.

Free PDF · the crash course

AI Agents for Marketing Crash Course

Learn how to deploy AI marketing agents across your go-to-market — the best tools, prompts, and workflows to turn your data into autonomous execution without writing code.

Using the SWITCH Function in DAX

The SWITCH function is a clean and highly readable way to handle multiple "if" conditions - similar to "Replace Values" but more powerful.

Step-by-Step Instructions:

  1. In Power BI Desktop, go to the Data View (the table icon on the left).
  2. Select the table you want to add a column to.
  3. From the ribbon, click New Column.
  4. In the formula bar, type your SWITCH formula.

The syntax is:

New Column = SWITCH ( TRUE(),
    condition_1, result_1,
    condition_2, result_2,
    ...,
    else_result
)

For a direct replacement scenario, say for renaming subscription plan tiers:

Current Tier = 
SWITCH(
    'Subscriptions'[Plan ID],
    "prod_basic_123", "Basic Plan",
    "prod_pro_456", "Pro Plan",
    "prod_ent_789", "Enterprise Plan",
    "Unknown"
)

After you press Enter, DAX evaluates the Plan ID for each row and populates the Current Tier column with the corresponding friendly name.

Quick Reference: Which Method Should You Use?

Final Thoughts

Cleaning and organizing your data by changing column values is essential for building accurate and insightful Power BI reports. By mastering the "Replace Values," "Conditional Column," and DAX functions, you have a complete toolkit to prepare your data exactly how you need it, whether you're tackling simple fixes or building complex business logic.

Transforming data manually across all your platforms is often the most time-consuming part of analytics. We built Graphed to solve this by ditching the repetitive work. Instead of spending hours in Power Query or wrangling CSVs, you simply connect your data sources (like Google Analytics, Shopify, or your CRM) and ask for the dashboard you need in plain English. Your data is automatically cleaned and visualized in real-time, letting you get straight to the insights.

Related Articles