+ Reply to Thread
Results 1 to 9 of 9

Embedded IF Than Statement Issue

  1. #1
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Embedded IF Than Statement Issue

    Example Excel: Example.xlsx.
    Below is the function I am using that is not working properly.{ =IF(A11=A10,"",IF(A11=A12=A13=A14=A15,C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"&";"&C12&"-"&D12&"-"&E12&"("&F12&"-"&G12&")"&";"&C13&"-"&D13&"-"&E13&"("&F13&"-"&G13&")"&";"&C14&"-"&D14&"-"&E14&"("&F14&"-"&G14&")"&" "&C15&"-"&D15&"-"&E15&"("&F15&"-"&G15&")",IF(A11=A12=A13=A14,C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"&";"&C12&"-"&D12&"-"&E12&"("&F12&"-"&G12&")"&")"&";"&C13&"-"&D13&"-"&E13&"("&F13&"-"&G13&")"&" "&C14&"-"&D14&"-"&E14&"("&F14&"-"&G14&")",IF(A11=A12=A13,C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"&";"&C12&"-"&D12&"-"&E12&"("&F12&"-"&G12&")"&";"&C13&"-"&D13&"-"&E13&"("&F13&"-"&G13&")"&,IF(A11=A12,C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"&";"&C12&"-"&D12&"-"&E12&"("&F12&"-"&G12&")"&,C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"))))) }

    The function works in most ways except for one, it does not combine more than a few pieces of information. I tried using the =CONCATENATE() function instead of using [&] but had the same result. If I pull out the function that combines data that works properly:
    { C11&"-"&D11&"-"&E11&"("&F11&"-"&G11&")"&";"&C12&"-"&D12&"-"&E12&"("&F12&"-"&G12&")"&";"&C13&"-"&D13&"-"&E13&"("&F13&"-"&G13&")"&";"&C14&"-"&D14&"-"&E14&"("&F14&"-"&G14&")"&" "&C15&"-"&D15&"-"&E15&"("&F15&"-"&G15&")}
    Is there an alternative method to solve this problem? Is there someone to change a setting so this actually works?
    I have a set of data with an identification code, I need to reduce the data down so there is only one identification code per the rest of the corresponding data. My function checks if there are multiple entries with the same identification code and combines the corresponding data into one cell.

    I believe excel is incapable of handling the function.
    Last edited by Lousiwu; 07-09-2013 at 06:11 PM. Reason: Attached Example

  2. #2
    Forum Contributor
    Join Date
    09-16-2009
    Location
    Dallas, TX
    MS-Off Ver
    Office 2013
    Posts
    107

    Re: Embedded IF Than Statement Issue

    Please, please attach a sample file. If there's a human alive that can read that formula and instantly know what it does, it's not me.

    Dan

  3. #3
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Embedded IF Than Statement Issue

    Sorry added an example file

  4. #4
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Embedded IF Than Statement Issue

    Test this in your file.

    Make A11 through A15 all an equal value, then in another cell...

    IF(A11=A12=A13=A14=A15,TRUE,FALSE)

  5. #5
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Embedded IF Than Statement Issue

    Well that seems to explain it, if I go past two things being equal it doesn't work!
    Thank you!
    Any idea on an alternative way to check this?

  6. #6
    Valued Forum Contributor
    Join Date
    05-20-2013
    Location
    Ohio, USA
    MS-Off Ver
    Excel 2013
    Posts
    941

    Re: Embedded IF Than Statement Issue

    Instead, try something like...

    IF(COUNTIF(A11:A15,A11)=5,TRUE,FALSE)

  7. #7
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Embedded IF Than Statement Issue

    I tried this:
    =IF(AND(A11=A12,A12=A13,A13=A14,A14=A15),TRUE,FALSE)
    and that worked, I'll fleche is out to the larger function to see if it works.

  8. #8
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Embedded IF Than Statement Issue

    It works! Thank you so much for the help jhren!!
    Here is the final working version: Example.xlsx

  9. #9
    Registered User
    Join Date
    07-09-2013
    Location
    USA
    MS-Off Ver
    Excel 2007
    Posts
    8

    Re: Embedded IF Than Statement Issue

    Thats much more streamlined I'll switch that that!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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