Flip a string with conditions

{ 2 Comments }

Assume a column with some IP addresses.  Each cell has 4 portions separate by a dot.  The number of digits in each portion can either be 2 or 3.  The following tasks need to be performed on this dataset:

1. Drop the last portion of the string
2. Flip the string
3. Add the following text to the flipped string – “in-addr.arpa” (without double quotes)

The base data and expected solution is shown below

While this can be resolved by writing formulas, I have shown a Power Query solution in this workbook.

You may also watch a short video of my solution here

Leave a Comment

Your email address will not be published.

*

  • Greetings Ashish,

    I’ve been reading some of your tutorial and you seem to be quite knowledgable about the VBA language of Excel. I’ve got a specific question for you about something that I am trying to do automatically with my workbook.

    Could you please provide me an email that I could provide you all the information?

    Thanking you in advance,
    Jonathan A.