Advanced Text-Splitting with Copilot in Excel

Share
Advanced Text-Splitting with Copilot in Excel

Excel's Copilot has evolved significantly with Wave 2, introducing powerful capabilities for advanced text manipulation. This blog post explores how to leverage Copilot for complex text-splitting tasks, specifically focusing on separating location data into distinct columns while handling special cases.

In the image below, Copilot wrote an IF function to add the county after the comma in column B to column C, but if it found two capital letters after the comma, it made the county USA.

Copilot split the county
Copilot split the county

The Challenge: Splitting Location Data

Our example dataset contains a "Location" column with a mix of countries and US states. The goal is to split this information intelligently:

- For countries, extract the country name after the comma - For US states, identify the two-letter abbreviation and output "USA"

This task requires more than simple text splitting - it demands conditional logic to handle different scenarios.

YouTube Video - Copilot in Excel: Advanced Text Splitting in Excel

Copilot in Excel: Advanced Text Splitting in Excel - YouTube

Copilot in Excel - Advanced Text Splitting

Setting Up the Exercise

To begin, we have a dataset with the following structure:

- Column A: Dates - Column B: Location (e.g., "Rome, Italy" or "Atlanta, GA")

Our objective is to create a new Column C that will contain either the country name or "USA" for states.

Date and Location fields
Date and Location fields

Leveraging Copilot for Advanced Text Splitting

Here's how to use Copilot to accomplish this task:

- Select your data range (no need to convert it to a table) - Open the Copilot task pane from the Home tab - In the prompt box, enter the following instruction:

**"Add a new column that extracts the country from column B. If the text after the comma is a two-letter capital abbreviation, put 'USA'. Otherwise, extract the text after the comma."**

Copilot Prompt Box for Advanced Splitting
Copilot Prompt Box for Advanced Splitting

Understanding Copilot's Solution

After processing your request, Copilot will generate a solution. Here's what to expect:

- Copilot will create a complex nested IF statement combined with the LET function - The formula will examine Column B, looking for the comma and the characters that follow - If it detects a two-letter capital abbreviation, it will output "USA" - For other entries, it will extract the text after the comma as the country name

Copilot's Solution
Copilot's Solution

Implementing the Copilot Split Column Excel Solution

To apply Copilot's solution:

- Review the generated formula in the Copilot pane - Click "Insert Column" to add the new column with the formula - Verify the results in your spreadsheet

The resulting Column C should now correctly display "USA" for states and the appropriate country names for other locations.

Benefits of Using Copilot for Complex Text Splitting

Utilizing Copilot for this task offers several advantages:

  • Time-saving: Copilot generates complex formulas instantly
  • Accuracy: The AI-powered solution handles edge cases effectively
  • Learning opportunity: Examining Copilot's formula can teach you advanced Excel techniques
  • Flexibility: The same approach can be adapted for similar text-splitting challenges

FAQ

Q: Can Copilot handle even more complex text-splitting scenarios?

A: Yes, Copilot is capable of handling a wide range of text splitting scenarios. You can describe more complex requirements in your prompt, and Copilot will attempt to generate an appropriate solution.

Q: Do I need to format my data as a table for Copilot to work?

A: No, Copilot can now work with table-less data. You can simply select a range of cells, and Copilot will be able to process it.

Q: What if I don't understand the formula Copilot generates?

A: Copilot provides an explanation of its solution. You can click "Show Explanation" to see a breakdown of what the formula does. This can be a great learning opportunity to understand advanced Excel functions.

Q: Can I modify the Copilot-generated formula after inserting it?

A: Absolutely! Once Copilot inserts the formula, you can edit it like any other Excel formula to fine-tune it for your specific needs.

Read more

Copilot Skills in PowerPoint - Live Stream on October 20, 2026

Copilot Skills in PowerPoint - Live Stream on October 20, 2026

𝗠𝗼𝘀𝘁 𝗣𝗼𝘄𝗲𝗿𝗣𝗼𝗶𝗻𝘁 𝘂𝘀𝗲𝗿𝘀 𝗸𝗻𝗼𝘄 𝗖𝗼𝗽𝗶𝗹𝗼𝘁 𝗰𝗮𝗻 𝗰𝗿𝗲𝗮𝘁𝗲 𝘀𝗹𝗶𝗱𝗲𝘀. 𝗙𝗮𝗿 𝗳𝗲𝘄𝗲𝗿 𝗸𝗻𝗼𝘄 𝗮𝗯𝗼𝘂𝘁 𝘁𝗵𝗲 𝟴 𝗯𝘂𝗶𝗹𝘁-𝗶𝗻 𝗖𝗼𝗽𝗶𝗹𝗼𝘁 𝗦𝗸𝗶𝗹𝗹𝘀 𝘁𝗵𝗮𝘁 𝗰𝗮𝗻 𝗰𝗼𝗺𝗽𝗹𝗲𝘁𝗲𝗹𝘆 𝗰𝗵𝗮𝗻𝗴𝗲 𝗵𝗼𝘄 𝘆𝗼𝘂 𝗯𝘂𝗶𝗹𝗱, 𝗶𝗺𝗽𝗿𝗼𝘃𝗲, 𝗮𝗻𝗱 𝗽𝗿𝗲𝘀𝗲𝗻𝘁 𝗮 𝗱𝗲𝗰𝗸. Join me live on October 20, 2026, at Noon Eastern as I demonstrate each Copilot Skill and show practical ways to use them in your presentations. PDF of the 8 Copilot Skills in Pow

By Chris Menard