Combining columns with dates

Hiker

New Member
Joined
Jun 15, 2011
Messages
33
Office Version
  1. 2013
Platform
  1. Windows
I'm trying to combine two columns into a third called membership_status_combined. I'm also working with two formats, one renewal column is blank for life and honorary life members and the other populates the column with 1/1/2050. I'd like both to be blank, so I'll most like need a formula for each.

I was able to concatenate (=CONCATENATE(B2,","," ",TEXT(C2,"DD/MM/YYYY")) in the first group of columns. The membership_level with renewal_date combined column looked fine but got an oddball date of 0/1/1900 after life and honorary life when the renewal date column was left blank.

The xl2bb example is what I want it to look like, no formulas were used.

Book1.xlsx
ABCDEFG
1membership_status_combinedmembership_levelrenewal_datemembership_status_combinedmembership_levelrenewal_date
21 Year, 11/9/20211 Year11/09/20211 Year, 11/9/20211 Year11/09/2021
3Honorary Life MemberHonorary Life MemberHonorary Life MemberHonorary Life Member01/01/2050
4Life MemberLife MemberLife MemberLife Member01/01/2050
52 Years, 5/17/20222 Years05/17/20222 Years, 5/17/20222 Years05/17/2022
61 Year Recurring, 5/16/20221 Year Recurring05/16/20221 Year Recurring, 5/16/20221 Year Recurring05/16/2022
Sheet1
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Assuming that the renewal_date column is text (because it is left-justified), I believe this formula for A2 should be able to handle either format:
Excel Formula:
=IF(OR(C2="",C2="01/01/2050"),B2,B2 & ", " & C2)
 
Upvote 0
That halfway worked. Here's the problem I run into.

Book1.xlsx
ABCDEFG
1membership_status_combinedmembership_levelrenewal_datemembership_status_combinedmembership_levelrenewal_date
21 Year, 445091 Year11/09/20211 Year, 445091 Year11/09/2021
3Honorary Life MemberHonorary Life MemberHonorary Life MemberHonorary Life Member01/01/2050
4Life MemberLife MemberLife MemberLife Member01/01/2050
52 Years, 446982 Years05/17/20222 Years, 446982 Years05/17/2022
61 Year Recurring, 446971 Year Recurring05/16/20221 Year Recurring, 446971 Year Recurring05/16/2022
Sheet1
Cell Formulas
RangeFormula
A2:A6A2=IF(OR(C2="",C2="01/01/2050"),B2,B2 & ", " & C2)
E2:E6E2=IF(OR(C2="",C2="01/01/2050"),B2,B2 & ", " & C2)
 
Upvote 0
Replace the last C2 (the one you are concatenating) to this...

TEXT(C2,"m/d/yyyy")
 
Upvote 0
Solution
Glad you got it figured out.

It looks like my assumption that your dates were text (because they were left justified) was not correct.
Either it is just the tool that you used to post the image, or you intentionally made them left justified (because by default, dates are right-justified when enter them into cells that do not have explicit justification set).

And Excel sees dates just as numbers (the number of days since 1/0/1900), so that is the number you were seeing.
So converting it to text and applying the date format like Rick showed is how you change that.
 
Upvote 0

Forum statistics

Threads
1,215,640
Messages
6,125,972
Members
449,276
Latest member
surendra75

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top