Extract unique values in a row excel

Excel98402

New Member
Joined
Oct 29, 2014
Messages
5
I am trying to extract unique values from a row in Excel and I am not sure how to do this. It should not be complicated. Unique values in a column is pretty simple. I am not sure why it is so tricky to do the same in row.

This is how the data looks. I am trying to extract unique values from each row. Example for the first record I need the values 8.99, 19. 9.99 in three separate columns. Not all records have 3 unique values. Some may have more or some may have less.

Any help would be appreciated.
Row Label</SPAN>10</SPAN>12</SPAN>14</SPAN>15</SPAN>16</SPAN>17</SPAN>18</SPAN>19</SPAN>21</SPAN>24</SPAN>25</SPAN>30</SPAN>31</SPAN>32</SPAN>35</SPAN>
363820</SPAN>8.99</SPAN> 19</SPAN>19</SPAN>9.99</SPAN>9.99</SPAN>9.99</SPAN>9.99</SPAN> 8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>
363846</SPAN>8.99</SPAN>8.99</SPAN>19</SPAN>19</SPAN>9.99</SPAN>9.99</SPAN>9.99</SPAN>9.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>8.99</SPAN>
369918</SPAN> 39</SPAN>39</SPAN>19.99</SPAN>19.99</SPAN>19.99</SPAN>19.99</SPAN> 19.99</SPAN>19.99</SPAN>19.99</SPAN>
370049</SPAN> 36.99</SPAN>36.99</SPAN>24.99</SPAN>36.99</SPAN>49</SPAN>36.99</SPAN> 36.99</SPAN>36.99</SPAN>36.99</SPAN>
370148</SPAN>59</SPAN>59</SPAN>55</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>59</SPAN>

<TBODY>
</TBODY><COLGROUP><COL><COL span=15></COLGROUP>
 
Hi billszysz,

Thank you so much. This actually worked.

What is the best way to learn VBA ? This stuff is really useful when working with Excel.
 
Upvote 0

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Are you suggesting that to make the change because you think that I am starting from D instead of B as in my example ?

If yes, that is not the case because when I pasted the data, I removed the data in the columns B and C to avoid confusion.

Would it help if I sent the raw data over ?

In that formula you can start the range in D2 like this:

=IFERROR(INDEX($D2:$AK2,MATCH(1,INDEX((COUNTIF($AL2:AL2,$D2:$AK2)=0)*($D2:$AK2<>""),0),0)),"")
 
Upvote 0

Forum statistics

Threads
1,215,219
Messages
6,123,690
Members
449,117
Latest member
Aaagu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top