+ Reply to Thread
Results 1 to 5 of 5

outcome of CONCATENATE function

  1. #1
    Registered User
    Join Date
    09-21-2010
    Location
    Nottingham
    MS-Off Ver
    2007
    Posts
    3

    Question outcome of CONCATENATE function

    I have used the CONCATENATE function to link together a few cells. The first is a number, the second text and the last 3 are dates.

    I am having a problem with the dates.

    If in the original cell the date is written for example as 12/02/12 then the formulated cell is showing as a date.
    If the original cell is written as 12/02/2012 the formulated cell is returning a number instead of a date

    The formula = =CONCATENATE(B6,", ",M6,", ",P6,", ",O6,", ",S6)
    The returned value = 51330, Pro MK 3, 20/10/11, 15/02/12, 41136

    I have tried changing the original cell format to dd/mm/yy but this makes no difference.

    Can you give me some other options to try.

    Thank you

  2. #2
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: outcome of CONCATENATE function

    Looks like P6 and O6 are not really dates, but just text strings that look like dates.
    But S6 really is an excel date, and the concatenate function is returning the Serial Date value of that date.

    Excel stores dates as serial numbers incrimenting by 1 from Jan 1st 1900
    1 = Jan 1 1900
    2 = Jan 2 1900
    etc
    41136 = Aug 15 2012
    41353 = March 20 2013

    to resolve, use the TEXT function on the REAL Date S6 to convert it to a text string

    =CONCATENATE(B6,", ",M6,", ",P6,", ",O6,", ",TEXT(S6,"dd/mm/yy"))
    Last edited by Jonmo1; 03-20-2013 at 09:08 AM.

  3. #3
    Forum Expert Kevin UK's Avatar
    Join Date
    12-07-2010
    Location
    Radstock, Somerset
    MS-Off Ver
    365
    Posts
    1,922

    Re: outcome of CONCATENATE function

    Hi clareleeder

    Try the following:
    =CONCATENATE(B6,", ",M6,", ",P6,", ",O6,", ",TEXT(S6,"dd/mm/yyyy"))

    Or:
    =B6&", "&M6&", "&P6&", "&O6&", "&TEXT(S6,"dd/mm/yyy")
    Regards Kevin


    Merged Cells (They are the work of the devil!!!)

  4. #4
    Registered User
    Join Date
    09-21-2010
    Location
    Nottingham
    MS-Off Ver
    2007
    Posts
    3

    Re: outcome of CONCATENATE function

    Thanks for this. It is now working

  5. #5
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: outcome of CONCATENATE function

    Glad to help, thanks for the feedback.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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