+ Reply to Thread
Results 1 to 2 of 2

Power Query - Replace If Text is Found

  1. #1
    Forum Contributor
    Join Date
    03-03-2011
    Location
    Ottawa, Ontario
    MS-Off Ver
    365
    Posts
    136

    Power Query - Replace If Text is Found

    I have a column in my query editor that I need to replace if a word is found in a cell. The column is all names that may have the text "- N/A" following. eg. "Bob Smith - N/A". I would like to be able to replace all the names that have "N/A" at the end of them with just the text "N/A". I am not sure if I have to make a new column or if this can be done another way.

  2. #2
    Forum Expert CK76's Avatar
    Join Date
    06-16-2015
    Location
    ONT, Canada
    MS-Off Ver
    MS365 Apps for enterprise
    Posts
    5,885

    Re: Power Query - Replace If Text is Found

    You can do this in several ways.

    1. Using custom function.
    2. Using calculated column.

    Calculated column is probably easier for you to implement.

    Add custom with following construct.
    Please Login or Register  to view this content.
    ?Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something.?
    ― Robert A. Heinlein

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Power Query: Reading a text or csv file that is publicly available on the Web?
    By learning new things in forum Excel General
    Replies: 6
    Last Post: 10-31-2018, 03:12 PM
  2. [SOLVED] Power Query - One works the other does not (replace with if statement) - Why?
    By learning new things in forum Excel General
    Replies: 13
    Last Post: 08-20-2018, 09:46 PM
  3. Sub-Forum for Excel Power Tools (Power Query, Power Pivot & Power BI)
    By chullan88 in forum Suggestions for Improvement
    Replies: 10
    Last Post: 06-28-2018, 02:25 PM
  4. [SOLVED] Power Query / Get & Transform filtering on text
    By SHI.NL in forum Excel General
    Replies: 5
    Last Post: 04-28-2018, 11:50 AM
  5. Replies: 0
    Last Post: 04-05-2018, 01:16 AM
  6. [SOLVED] Power Query - Find and Replace Line Breaks
    By ibuhary in forum Excel General
    Replies: 4
    Last Post: 03-27-2018, 05:33 AM
  7. Power query - replace all contents if word appears
    By rewdsaDSAdas in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-08-2017, 04:27 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1