SOLVED
Home

How to handle table returned from lookupvalue function?

%3CLINGO-SUB%20id%3D%22lingo-sub-756449%22%20slang%3D%22en-US%22%3EHow%20to%20handle%20table%20returned%20from%20lookupvalue%20function%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-756449%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3EI%20have%20recently%20been%20asked%20a%20question%20relating%20data%20imported%20from%20a%20csv%20file%20into%20Excel%20worksheet.%20I%20want%20to%20know%20name%20of%20the%20cities%20with%20lowest%20and%20highest%20revenue.%20I%20did%20some%20online%20research%20and%20I%20found%20out%20that%20lookupvalue%20function%20can%20be%20useful%20in%20solving%20this%20problem.%20However%2C%20I%20didn't%20find%20any%20topic%20pertaining%20to%20handling%20the%20result%20of%20this%20function%20when%20it's%20a%20table%20(multiple%20value).%20I%20appreciate%20it%20if%20you%20can%20help%20me.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-756449%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-756495%22%20slang%3D%22en-US%22%3ERe%3A%20How%20to%20handle%20table%20returned%20from%20lookupvalue%20function%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-756495%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F376937%22%20target%3D%22_blank%22%3E%40amin96%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPlease%20attach%20your%20sample%20file.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-756836%22%20slang%3D%22en-US%22%3ERe%3A%20How%20to%20handle%20table%20returned%20from%20lookupvalue%20function%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-756836%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F280482%22%20target%3D%22_blank%22%3E%40Twifoo%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHere%20is%20the%20sample%20file.%20But%20beware%20that%20the%20data%20in%20city%20column%20should%20be%20split%20to%20include%20only%20the%20city%20name%20(since%20the%20state%20and%20country%20has%20their%20own%20dedicated%20columns).%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-756942%22%20slang%3D%22en-US%22%3ERe%3A%20How%20to%20handle%20table%20returned%20from%20lookupvalue%20function%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-756942%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F376937%22%20target%3D%22_blank%22%3E%40amin96%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHi%3C%2FP%3E%3CP%3EI%20inserted%20two%20columns%20after%20City%2C%20then%20selected%20column%20F%20and%20did%20Data%20%26gt%3B%20Text%20to%20Columns%20%26gt%3B%20Comma%20delimiter%20to%20split%20out%20State%20and%20Country.%20I%20then%20deleted%20the%20inserted%20columns%20G%20and%20H.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20inserted%204%20rows%20at%20the%20top%20of%20the%20sheet%20and%20in%20cell%20F2%20entered%20the%20formula%3C%2FP%3E%3CP%3E%3DINDEX(F6%3A%24F%245523%2CMATCH(MAX(E6%3AE5523)%2C%24E%246%3A%24E%245523%2C0))%20for%20the%20max%20value%3C%2FP%3E%3CP%3E%3DINDEX(F7%3A%24F%245523%2CMATCH(MIN(E6%3AE5523)%2C%24E%246%3A%24E%245523%2C0))%20for%20the%20min%20value%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESee%20attached%20file%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-757394%22%20slang%3D%22en-US%22%3ERe%3A%20How%20to%20handle%20table%20returned%20from%20lookupvalue%20function%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-757394%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F200080%22%20target%3D%22_blank%22%3E%40Roger%20Govier%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EHi%20Roger%2C%3C%2FP%3E%3CP%3EThank%20you%20for%20helping%20me%20in%20this.%20Have%20a%20nice%20day.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EBest%20regards%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
amin96
New Contributor

Hi,

I have recently been asked a question relating data imported from a csv file into Excel worksheet. I want to know name of the cities with lowest and highest revenue. I did some online research and I found out that lookupvalue function can be useful in solving this problem. However, I didn't find any topic pertaining to handling the result of this function when it's a table (multiple value). I appreciate it if you can help me.

4 Replies

@amin96 

Please attach your sample file.

@Twifoo 

Here is the sample file. But beware that the data in city column should be split to include only the city name (since the state and country has their own dedicated columns).

Solution

@amin96 

 

Hi

I inserted two columns after City, then selected column F and did Data > Text to Columns > Comma delimiter to split out State and Country. I then deleted the inserted columns G and H.

 

I inserted 4 rows at the top of the sheet and in cell F2 entered the formula

=INDEX(F6:$F$5523,MATCH(MAX(E6:E5523),$E$6:$E$5523,0)) for the max value

=INDEX(F7:$F$5523,MATCH(MIN(E6:E5523),$E$6:$E$5523,0)) for the min value

 

See attached file

@Roger Govier 

Hi Roger,

Thank you for helping me in this. Have a nice day.

 

Best regards

 

Related Conversations
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
14 Replies
Tabs and Dark Mode
cjc2112 in Discussions on
23 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies