Welcome to the Smartsheet Forum Archives


The posts in this forum are no longer monitored for accuracy and their content may no longer be current. If there's a discussion here that interests you and you'd like to find (or create) a more current version, pleaseVisit the Current Forums.

How to index + match with multiple criteria ?

Hi!

I'm trying to figure out how to do the following excel formula in Smartsheet, but I am having trouble with it. Can I get some help please ?

Basically what I need to do is match 3 different criteria (lookup 1 -3) with 3 different collumns(part 1 - 3) and when those match they have to give me the corresponding Time.

This is the excell formula : =INDEX(D1:D4;MATCH(1;(A6=A1:A4)*(B6=B1:B4)*(C6=C1:C4);0))

problem1.jpg

problem1B.jpg

«1

Comments

  • Taylor F
    Taylor F Employee Admin

    I tried to set up your example in Excel percisly the way that you have it outlined in your screenshot and I receive an error message.

    INDEX has two required arguments. The first is the range of of the cells you would like to return. You have this with your D1:D4. The second is the row number which you are using MATCH to provide. This will work.

    MATCH has two required arugments. The first is the value you are looking for. The second is a range you are looking for the value in.

    (A6=A1:A4)*(B6=B1:B4)*(C6=C1:C4)

    This is what you are using inte range argument of the MATCH. Breaking this up (without getting it to work in Excel) it appears that each section would produce a number of where row 6's value is located in the first four rows. Then it will multiple these numbers which would return an numeric value and not a range which MATCH is expecting in this argument.

    This formula won't be able to be created in Smartsheet since MATCH isn't being provided a range.

    If you have any questions or would like to dive into this further, please reach out to us submitting this form:https://help.smartsheet.com/contactand we will be happy to assist you.

    -Taylor

  • @TaylorF

    Thank you for the help!

    The excell formula does work, Have you remembered to press Ctrl + Shift + Enter when using the formulae ? else it will not work and give you an error.

    Either way I have managed to solve this problem in another way.

    I Sum up all input into one big String value, then compare that to a database with all possible string value's and corresponding needed value as output.

    Anyways, thanks again for hte help!

  • Yannick,

    I'm trying to do the same thing. Can you share your solution?

  • Wilbsguy
    Wilbsguy ✭✭✭

    我知道这是旧的但是希望这可以帮助任何人else that wants this. What you want is another index formula within the match formula. So an index-match-index formula.

    =INDEX(Time1:Time9, MATCH(1, INDEX(([lookup 1]1 = [part 1]1:[part 1]9)* ([lookup 2]1 = [part 2]1:[part 2]9)* ([lookup 3]1 = [part 3]1:[part 3]9)),0,1), 0))

  • Wilbsguy
    Wilbsguy ✭✭✭

    I know it has been a while but if you still need something, I gave an answer. Let me know if you have any questions on it.

  • ON
    ON

    Hi All, Tacking onto the end of someone else's issue with my own...

    I'm trying to make the formula above work with reference sheets:

    =INDEX({Budget Day Rate}, MATCH(1, INDEX((Loc9 = {Budget Loc}) * ([Column3]9 = {Budget Role})), 0, 1), 0)

    The above returns #INCORRECT ARGUMENT SET

    Have also Tried:

    =INDEX({Budget Day Rate}, MATCH(1, (Loc7 = {Budget Loc}) * ([Column3]7 = {Budget Role}), 0))

    The above returns #INVALID OPERATION

    {Budget Day Rate} = The day rate column in a rate card sheet

    {Budget Loc} = The Location Column "UK" "US" etc

    {Budget Role} = Column with Job title

    My aim is to return the value from the "day rate column" If the Location and Job Title Match. A US Project Manager may earn a higher day rate than a UK Project Manager on the rate card. Any input on this would be amazing!

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭

    Hi,

    You could maybe use a JOIN function to get the values together and only match that.

    Would that work?

    Can you describe your process in more detail and maybe share some screenshots? (Delete/replace any confidential/sensitive information before sharing) That would make it easier to help.

    Have a fantastic weekend!

    Best,

    Andrée Starå

    Workflow Consultant @ Get Done Consulting

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå| Workflow Consultant / CEO @WORK BOLD

    W:www.workbold.com| E:[email protected]| P: +46 (0) - 72 - 510 99 35

    Feel free to contact me about help with Smartsheet, integrations, general workflow advice, or something else entirely.

  • ON
    ON
    edited 07/05/19

    Hi Andree,

    Please see attached screen shot. If you're interested the sheets are in the shared workspace I created for you the other day for the checkbox formula Q I have elsewhere :-)

    Basically, If Loc cell and Job Title cell in the same row, both match the respective value in the same row on the reference sheet (or lookup table) then I want to return the value in the third column of the reference sheet.

    Ref Sheet, "Project Manager" in the "UK" day rate is "£10". In my budget sheet I want to return the value of "£10" in the "Day Rate" column if the "Loc" and "Job Title" match the values on the Rate card.

    Thanks for looking!! :-)

    Screenshot 2019-07-05 at 15.53.07.png

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭

    Thanks!

    I'll take a look and get back to you! (for both)wink

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå| Workflow Consultant / CEO @WORK BOLD

    W:www.workbold.com| E:[email protected]| P: +46 (0) - 72 - 510 99 35

    Feel free to contact me about help with Smartsheet, integrations, general workflow advice, or something else entirely.

  • ON
    ON

    Thank you!

    FYI - I had previously asked my question in it's own thread:https://community.smartsheet.com/discussion/matching-multiple-values-multiple-columns-linked-sheet-fill-cell-content-third-column#comment-184841

    Just managed to make the following do what I need:

    =JOIN(COLLECT({Budget Day Rate}, {Budget Loc}, Loc@row, {Budget Role}, [Job Title]@row))

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭

    Excellent!

    One left!wink

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå| Workflow Consultant / CEO @WORK BOLD

    W:www.workbold.com| E:[email protected]| P: +46 (0) - 72 - 510 99 35

    Feel free to contact me about help with Smartsheet, integrations, general workflow advice, or something else entirely.

  • ON
    ON

    Actually that doesn't work - it returns the value I want but I then can't do anything with it... It breaks the formula in the next Column. It also won't take "£" formatting etc.

    Soooo Close...

  • Andrée Starå
    Andrée Starå ✭✭✭✭✭✭

    Hi,

    Did you get it working?

    Have a fantastic day!

    Best,

    Andrée Starå

    Workflow Consultant @ Get Done Consulting

    SMARTSHEET EXPERT CONSULTANT & PARTNER

    Andrée Starå| Workflow Consultant / CEO @WORK BOLD

    W:www.workbold.com| E:[email protected]| P: +46 (0) - 72 - 510 99 35

    Feel free to contact me about help with Smartsheet, integrations, general workflow advice, or something else entirely.

  • ON
    ON

    Hi Andree,

    I am able to pull the right value BUT there is an issue with the column at that point, it won't allow me to use "£" formatting or do anything with the output. Other cells also don't see the output as a number which means it can't be used in a "SUM" in a different cell.

    I tried to cheat and created a new column that used ="other cell" but it clones the issue...

    Thanks for checking in.

    O

  • ON
    ON

    The long and short of it is, I wan't to match the day rate to the user based on Location/Job role. That I can now do... but the £ value day rate is not seen as a number value. This means I can't then multiply the users correct day rate against the total number of days worked to give me a total cost of that user.

    If "Olly" is based in "UK" and his Job is "Project Manager" his day rate is "£10" I will get a value of "10" in the cell, I want to make that a £ value and then multiply it by the 20 days worked which gives a total cost for Olly for that month of £200

This discussion has been closed.
Try this:<\/p>

=COUNTIFS([Item Number]:[Item Number], OR(@cell = \"C001\", @cell = \"COO2\", @cell = \"COO3\", @cell = \"COO4\"), [Status]:[Status], OR(@cell = \"Green\", @cell = \"Yellow\", @cell = \"Red\"))<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"formulas","name":"Formulas"}]},{"discussionID":109490,"type":"question","name":"HAS exact match within multiselect - Numbered Values","excerpt":"Scenario: Trying to identify a match if a value shows up in a multiselect from another sheet. Approach: I'm able to get 95% of this done through an index(collect(contains))) formula, but having some false positives show up wherever a partial match is found. I later found some suggestions that (has) would be more…","snippet":"Scenario: Trying to identify a match if a value shows up in a multiselect from another sheet. Approach: I'm able to get 95% of this done through an index(collect(contains)))…","categoryID":322,"dateInserted":"2023-08-25T19:26:32+00:00","dateUpdated":null,"dateLastComment":"2023-08-26T00:49:48+00:00","insertUserID":154049,"insertUser":{"userID":154049,"name":"Rob W.","url":"https:\/\/community.smartsheet.com\/profile\/Rob%20W.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-26T00:49:37+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":null,"lastUserID":154049,"lastUser":{"userID":154049,"name":"Rob W.","url":"https:\/\/community.smartsheet.com\/profile\/Rob%20W.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-26T00:49:37+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":2,"countViews":16,"score":null,"hot":3386003780,"url":"https:\/\/community.smartsheet.com\/discussion\/109490\/has-exact-match-within-multiselect-numbered-values","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/109490\/has-exact-match-within-multiselect-numbered-values","format":"Rich","lastPost":{"discussionID":109490,"commentID":392694,"name":"Re: HAS exact match within multiselect - Numbered Values","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/392694#Comment_392694","dateInserted":"2023-08-26T00:49:48+00:00","insertUserID":154049,"insertUser":{"userID":154049,"name":"Rob W.","url":"https:\/\/community.smartsheet.com\/profile\/Rob%20W.","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-08-26T00:49:37+00:00","banned":0,"punished":0,"private":false,"label":"✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Get Help","url":"https:\/\/community.smartsheet.com\/categories\/get-help"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"image":{"url":"https:\/\/us.v-cdn.net\/6031209\/uploads\/KJPRLKL2FW16\/capture-png.png","urlSrcSet":{"10":"","300":"","800":"","1200":"","1600":""},"alt":"Capture.PNG"},"attributes":{"question":{"status":"accepted","dateAccepted":"2023-08-26T00:49:35+00:00","dateAnswered":"2023-08-25T23:58:23+00:00","acceptedAnswers":[{"commentID":392688,"body":"

Hi, <\/p>

Instead of applying the formula to \"Multiselect Text String\" row, did you tried with \"Multiselect Values\" row?<\/p>

=IF(HAS([Multiselect Values]@row, [Component ID]@row), \"MATCH\", \"NO MATCH\")<\/p>

Thank you,<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]},{"discussionID":109474,"type":"question","name":"Help with date calculation formula","excerpt":"Hello, I'm trying to find a formula that will help me calculate how long an intake took to resolve. The rows I need to be calculated are Date Reported & Resolution Date. If the resolution date is blank I want it to use the current date in the calculation to see how long this issue has gone unresolved. Any help is much…","snippet":"Hello, I'm trying to find a formula that will help me calculate how long an intake took to resolve. The rows I need to be calculated are Date Reported & Resolution Date. If the…","categoryID":322,"dateInserted":"2023-08-25T16:29:39+00:00","dateUpdated":"2023-08-25T16:29:59+00:00","dateLastComment":"2023-08-25T23:01:30+00:00","insertUserID":165688,"insertUser":{"userID":165688,"name":"Nwest","title":"Systems Analyst","url":"https:\/\/community.smartsheet.com\/profile\/Nwest","photoUrl":"https:\/\/aws.smartsheet.com\/storageProxy\/image\/images\/u!1!ukHVZ18ImX4!BcjWAe8S9SY!l7iQo_PZHOx","dateLastActive":"2023-08-25T17:22:30+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":165688,"lastUserID":8888,"lastUser":{"userID":8888,"name":"Andrée Starå","title":"Smartsheet Expert Consultant & Partner | Workflow Consultant \/ CEO @ WORK BOLD","url":"https:\/\/community.smartsheet.com\/profile\/Andr%C3%A9e%20Star%C3%A5","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/0PAU3GBYQLBT\/nXWM7QXGD6464.jpg","dateLastActive":"2023-08-26T14:46:22+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":3,"countViews":23,"score":null,"hot":3385987269,"url":"https:\/\/community.smartsheet.com\/discussion\/109474\/help-with-date-calculation-formula","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/109474\/help-with-date-calculation-formula","format":"Rich","tagIDs":[254],"lastPost":{"discussionID":109474,"commentID":392687,"name":"Re: Help with date calculation formula","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/392687#Comment_392687","dateInserted":"2023-08-25T23:01:30+00:00","insertUserID":8888,"insertUser":{"userID":8888,"name":"Andrée Starå","title":"Smartsheet Expert Consultant & Partner | Workflow Consultant \/ CEO @ WORK BOLD","url":"https:\/\/community.smartsheet.com\/profile\/Andr%C3%A9e%20Star%C3%A5","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/userpics\/0PAU3GBYQLBT\/nXWM7QXGD6464.jpg","dateLastActive":"2023-08-26T14:46:22+00:00","banned":0,"punished":0,"private":false,"label":"✭✭✭✭✭✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Get Help","url":"https:\/\/community.smartsheet.com\/categories\/get-help"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-08-25T17:04:22+00:00","dateAnswered":"2023-08-25T16:36:59+00:00","acceptedAnswers":[{"commentID":392622,"body":"

\n \n https:\/\/community.smartsheet.com\/discussion\/109474\/help-with-date-calculation-formula\n <\/a>\n<\/div>\n

Hi, <\/p>

I hope you're well and safe!<\/p>

Try something like this.<\/p>

=IF([Date Reported]@row <> \"//www.santa-greenland.com/community/discussion/7328/\", IF([Resolution Date]@row = \"//www.santa-greenland.com/community/discussion/7328/\", NETDAYS([Date Reported]@row, TODAY()), NETDAYS([Date Reported]@row, [Resolution Date]@row)))<\/p>

Did that work\/help? <\/p>

I hope that helps!<\/p>

Be safe, and have a fantastic weekend!<\/p>

Best,<\/p>

Andrée Starå<\/strong><\/a> | Workflow Consultant \/ CEO @ WORK BOLD<\/strong><\/a><\/p>

Did my post(s) help or answer your question or solve your problem? Please support the Community by <\/em>marking it Insightful\/Vote Up, Awesome, or\/and as the accepted answer<\/em><\/strong>. It will make it easier for others to find a solution or help to answer!<\/em><\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[{"tagID":254,"urlcode":"formulas","name":"Formulas"}]}],"initialPaging":{"nextURL":"https:\/\/community.smartsheet.com\/api\/v2\/discussions?page=2&includeChildCategories=1&type%5B0%5D=Question&excludeHiddenCategories=1&siteSectionID=0&sort=-hot&limit=3&expand%5B0%5D=all&expand%5B1%5D=-body&expand%5B2%5D=insertUser&expand%5B3%5D=lastUser&status=accepted","prevURL":null,"currentPage":1,"total":10000,"limit":3},"title":"Trending Posts","subtitle":null,"description":null,"noCheckboxes":true,"containerOptions":[],"discussionOptions":[]}">

Trending Posts