How to Combine Two Cells in Excel with a Dash (5 Methods)

Let’s consider a scenario where a car dealer gives its cars code with this format: Car Model-Year. We have taken a dataset consisting of Car Model, Year, and Car Code as headers.

How to Combine Two Cells in Excel with a Dash


How to Combine Two Cells in Excel with a Dash: 5 Easy Ways

Method 1 – Using the Ampersand Operator to Combine Two Cells in Excel with a Dash

We can use the Ampersand symbol (&) for joining two cells.

Steps:

  • Select cell D5.
  • Insert the following formula:
=B5&"-"&C5

We are joining cells B5 and C5 with a dash (“-”) by using the Ampersand operator.

How to Combine Two Cells in Excel with a Dash

  • Press Enter.

How to Combine Two Cells in Excel with a Dash

  • The value of the two cells is combined with a dash.
  • Move the cursor to the right-bottom corner of the cell to bring up the Fill Handle (+) icon.
  • Drag down to AutoFill the cells with the formula.

How to Combine Two Cells in Excel with a Dash

  • The table should look like this.

Read More: How to Combine Cells into One with Line Break in Excel


Method 2 – Utilizing the CONCAT Function to Combine Two Cells in Excel with a Dash

If you have an older version of Excel, you can use the CONCATENATE function from method 4.

Steps:

  • Use this formula in cell D5.
=CONCAT(B5,"-",C5)

How to Combine Two Cells in Excel with a Dash

  • Press Enter.

  • Bring up the Fill Handle.
  • Double Click on the icon (+).

How to Combine Two Cells in Excel with a Dash

  • The rest of the cells will be AutoFilled with the formula.

Read More: How to Concatenate Multiple Cells in Excel


Method 3 – Combine Two Cells in Excel with a Dash Using the TEXTJOIN Function

Steps:

  • Select the cell range D5:D13.
  • Enter the following formula:
=TEXTJOIN("-",TRUE,B5,C5)

We are setting dash as our delimiter. The second value is set to TRUE, which means we’re ignoring the empty cells. You can set it to FALSE to include empty cells. The last two values are our two cells.

How to Combine Two Cells in Excel with a Dash

  • Press Ctrl + Enter.
  • This will Fill the formula into the selected cells.

  • Here’s the result.

How to Combine Two Cells in Excel with a Dash

Read More: Concatenate Multiple Cells Based on Criteria in Excel


Method 4 – Applying the CONCATENATE Function to Combine Two Cells in Excel with a Dash

Steps:

  • Use this formula in cell D5.
=CONCATENATE(B5,"-",C5)

  • Press Enter.

How to Combine Two Cells in Excel with a Dash

  • You can use the Fill Handle to AutoFill the formula to the rest of the cells. You can also use the Fill Down command to do so too.
  • Select cell D6.
  • From the Home tab, select Fill then choose Down.

Alternatively, you can use Ctrl + D to fill down. You can do this for the rest of the cells.

  • Here’s the result.

How to Combine Two Cells in Excel with a Dash

Read More: Combine Multiple Cells into One Separated by Comma in Excel


Method 5 – Combine Text and Date with a Dash in Excel

We have a new dataset with a list of the most commonly sold cars on a given date. We want to add those two columns to our Code column.

Before jumping into the steps, let’s see how the combination would look if we use our Ampersand method. We can see the date is in a weird format. To format the dates, we need to use the TEXT function.

How to Combine Two Cells in Excel with a Dash

Steps:

  • Use this formula in cell D5.
=TEXT(B5,"dd-mm-yy")&"-"&C5

The TEXT function will format cell B5 as date-month-year. Ampersand will join this formatted value with cell C5.

  • Press Enter.

How to Combine Two Cells in Excel with a Dash

  • AutoFill to the rest of the column however you want.

  • Here’s the result.

How to Combine Two Cells in Excel with a Dash

Read More: Concatenate Multiple Cells but Ignore Blanks in Excel


Practice Section

You can practice these methods using our provided practice tables in the Excel sheet.

How to Combine Two Cells in Excel with a Dash


Download the Practice Workbook


Related Articles


<< Go Back To Excel Concatenate Multiple Cells | Concatenate Excel | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Rafiul Haq
Rafiul Haq

Rafiul Haq worked as an Excel and VBA Content Developer in Exceldemy for over two years and published almost 200 articles for the website. He is passionate about exploring new aspects of Excel and VBA. He received his Bachelor of Science in Mechanical and Production Engineering (MPE) from the Islamic University of Technology. Rafiul furthered his education by obtaining an MBA in Finance from the Institute of Business Administration (IBA) at the University of Dhaka. Apart from creating... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo