+ Reply to Thread
Results 1 to 11 of 11

Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

  1. #1
    Registered User
    Join Date
    01-07-2016
    Location
    FL, USA
    MS-Off Ver
    2007
    Posts
    22

    Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    With the help of the online community, I've been piecing together solutions to a moderately complex solution. I'm hoping this post can tie them all together.

    This first function identifies the name of a supplier based on its URL and creates a unique 3-character code based on a lookup table. This one function applies to any URL.

    Please Login or Register  to view this content.
    A2 = www. walmart.com/ip/33857317
    B2 = WAL

    The next set of functions properly identifies the item number (a specific section of a website's URL). Note however that each website has its own unique syntax; therefore, for this function to dynamically work, it must reference an array that tells it which appropriate function to use to yield the desired result (based on supplier URL).

    Please Login or Register  to view this content.
    A2 = www. walmart.com/ip/33857317

    The arrays are found on the REFERENCE tab. The arrays are named ranges:

    SUPP_PREFIX
    SUPP_ITEM

    A challenge I see is that in the SUPP_ITEM array, cell references are hard-coded into the listed functions (which worked when I used them individually because when I would pull the functions down, the cell references would auto-update). In this case however, how can instances of cell reference "A1" be made to vary or apply to the line in which it is being executed upon?

    Tying the two main functions to generate a SKU dynamically based on a given supplier URL is the end goal.

    Examples:

    SUPP URL
    www .walmart.com/ip/33857317
    www. samsclub.com/sams/118235.ip
    www. costco.com/Aquaterra-Spas-Ventura-96-jet%2c-6-person-Spa.product.100355896.html

    DESIRED OUTCOME
    WAL-33857317
    SAM-118235
    COS-100355896

    A sample workbook is attached.

    Thanks for your input!
    Attached Files Attached Files

  2. #2
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    As long as the SKUs don't exceed 15 characters in length this combines both parts in one formula.

    Note the SKU extraction part of this formula is not my creation. I've borrowed shamelessly from someone named Lori. (I've lost the source thread.)

    Array enter this in B8 and fill down. If you aren’t familiar with array-entered formulas array enter means the formula must be committed from edit mode by simultaneously pressing and holding down Ctrl and Shift while hitting Enter.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Last edited by FlameRetired; 05-16-2018 at 12:31 AM.
    Dave

  3. #3
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    If the SKUs are longer than 15 characters you will need VBA.

  4. #4
    Registered User
    Join Date
    01-07-2016
    Location
    FL, USA
    MS-Off Ver
    2007
    Posts
    22

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    Quote Originally Posted by FlameRetired View Post
    If the SKUs are longer than 15 characters you will need VBA.
    Thanks, the SKUs can and usually do exceed 15 characters (up to 40). Hopeful there is a non-VBA solution, because that'll take me further down the rabbit hole which I am not familiar with.

  5. #5
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    In that case please upload an Excel workbook more representative of what the source data actually looks like. There may be other exceptions to handle. I can include a user defined function and formula that shouldn't be much trouble to use.

    To attach a file to your post: (Please no pics or screenshots ... saves retyping data.),
    • be sure to desensitize the data
    • click “Go Advanced” (next to Post Quick Reply – bottom right),
    • scroll down until you see “Manage Attachments”, click that,
    • click “Browse”.
    • select your file(s)
    • click “Upload”
    • click “Close window”
    • click “Submit Reply”

    The file name will appear at the bottom of your reply.

  6. #6
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    In the meantime pending any additional exceptions try this
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  7. #7
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    This is slightly shorter and does not have to be array entered.
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    01-07-2016
    Location
    FL, USA
    MS-Off Ver
    2007
    Posts
    22

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    Quote Originally Posted by FlameRetired View Post
    This is slightly shorter and does not have to be array entered.
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Ok, I'll give it a shot and let you know my results. Thanks again

  9. #9
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    This variation of Post #6 will return all the SKUs.
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    01-07-2016
    Location
    FL, USA
    MS-Off Ver
    2007
    Posts
    22

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    Quote Originally Posted by FlameRetired View Post
    This variation of Post #6 will return all the SKUs.
    That did the trick and satisfies the need I had, thanks a lot!

  11. #11
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 v 2403
    Posts
    13,406

    Re: Combining Multiple Individual Functions Into One With Dynamic Lookup Capability

    You're welcome. Thanks for the feedback and rep.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Combining lookup functions with data validation
    By ieumts in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-27-2016, 05:07 PM
  2. [SOLVED] Combining V-Lookup and Transpose Functions
    By GoGoeGo in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 01-01-2016, 08:53 AM
  3. Combining Multiple IF(COUNTIF) Functions
    By threadVirus in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-13-2015, 06:32 PM
  4. Combining multiple functions>lookup/sum functions
    By mush106 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-22-2013, 07:47 AM
  5. Need help combining an IF statement and lookup, choose, or match functions
    By sixsteps268 in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 05-20-2013, 03:28 PM
  6. Replies: 0
    Last Post: 05-04-2011, 06:26 PM
  7. [SOLVED] Combining LOOKUP and COUNTIF functions
    By kate_suzanne in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 08-22-2006, 02:05 AM

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