apelsunkist
New Member
- Joined
- Dec 12, 2012
- Messages
- 10
hello,
before i start my question, i would like to said thank you to you guys in this forum. im working on something that was complicated for me, since i almost have no knowledge on most excel formula before, but by reading questions and answers in this forum i was able to built it bit by bit. and it almost done, just several last thing to done. this below is one of those last thing, where i get stuck on :P
i'm trying to extract unique value among duplicates. it is do really not that complicated, but when combined with condition and the need to automation, my eyes gone swirled a bit :P . could you guys inspire to how to accomplish this?
any helps would be appreciated
here is the sample :
the source table would be :
<tbody>
</tbody>
the result wanted is :
to extract unique value (of the customer name), and where the word "less" become the keyword for condition (and automation).
such this :
<tbody>
</tbody>
to be exact, the condition would be :
1. extract customer name, which pay less than they should be (indicated by "less" in column-D). the value in column-I (name) would appear by it self with aoutomation,
2. colect unique value only from the name column (column-B).
3. take the result that is the latest date. in hanson example, mar-7 is the latest date from hanson.
a same name could be repeated with different bill number, but they are still a same person. and the same name and bill number could also be repeated for they can split the payment in twice or more. so the bill number is not an issue, the name alone that would distinct.
the range in initial table could be very long, and the amount of customers that is paid less, could not be predicted (thats why i use automation, so that they pop-up by them selves if there is one who paid less, or would stay empty if there is no one meets that citeria).
so far im using :
in i2 : =countif(d2:d8;i1)
in i5 : = IF(ROWS(i$5:i5)<=i$2;INDEX($b$2:$b$8;SMALL(IF($d$2:$d$8=i$1;ROW($b$2:$b$8)-ROW($b$2)+1);ROWS(i$5:i5)));"")
enter with Ctrl+Shift+Enter than drag down to necessary range.
than using index in L5 : =IF(i5="";"";INDEX($e$2:$e$8;MATCH(i5;$b$2:$b$8;0);0)) and drag down. since the amount would be same for each person, even with different bill number, the index combined with match are sufficient for fulfill this.
i got the automation formula in col-i from mr. Aladin Akyurek and mr. PaddyD answer in other thread.
and the index and match is also from other thread.
the result is :
<tbody>
</tbody>
the formula for automation is miraculous. and i have been using this for various other uses in other table.
but in this issue, i think the formula is need to be modified a bit, so that it could give only a unique result. (as shown above, the name hanson is repeated, where the desired result is only each unique name show up once)
i got an impression that if the column-I (name) has settled i could use
index + match for column-L, to get the amount
and use lookup for column-H to get the latest date payment from the person name (or i do wrong?).
but the problem is the column-I. could you guys suggest on something?
i'm sory if this is a double post where some one else is already asking about it some where. i have try to search a bit, with several keywords, and read a bit. but my eyes are already swirled @_@ :P
before i start my question, i would like to said thank you to you guys in this forum. im working on something that was complicated for me, since i almost have no knowledge on most excel formula before, but by reading questions and answers in this forum i was able to built it bit by bit. and it almost done, just several last thing to done. this below is one of those last thing, where i get stuck on :P
i'm trying to extract unique value among duplicates. it is do really not that complicated, but when combined with condition and the need to automation, my eyes gone swirled a bit :P . could you guys inspire to how to accomplish this?
any helps would be appreciated
here is the sample :
the source table would be :
A | B | C | D | E | |
1 | date | name | bill number | payment | amount |
2 | mar-1 | hanson | 5001 | less | (2000) |
3 | mar-4 | hanson | 5022 | less | (2000) |
4 | mar-6 | tika | 6225 | less | (3500) |
5 | mar-7 | hanson | 5022 | less | (2000) |
6 | mar-8 | galuh | 4008 | more | 3000 |
7 | mar-8 | tika | 6225 | less | (3500) |
8 | mar-8 | lulu | 5758 | less | (500) |
<tbody>
</tbody>
the result wanted is :
to extract unique value (of the customer name), and where the word "less" become the keyword for condition (and automation).
such this :
H | I | L | |
1 | date | name | amount |
2 | mar-7 | hanson | (2000) |
3 | mar-8 | tika | (3500) |
4 | mar-8 | lulu | (500) |
<tbody>
</tbody>
to be exact, the condition would be :
1. extract customer name, which pay less than they should be (indicated by "less" in column-D). the value in column-I (name) would appear by it self with aoutomation,
2. colect unique value only from the name column (column-B).
3. take the result that is the latest date. in hanson example, mar-7 is the latest date from hanson.
a same name could be repeated with different bill number, but they are still a same person. and the same name and bill number could also be repeated for they can split the payment in twice or more. so the bill number is not an issue, the name alone that would distinct.
the range in initial table could be very long, and the amount of customers that is paid less, could not be predicted (thats why i use automation, so that they pop-up by them selves if there is one who paid less, or would stay empty if there is no one meets that citeria).
so far im using :
in i2 : =countif(d2:d8;i1)
in i5 : = IF(ROWS(i$5:i5)<=i$2;INDEX($b$2:$b$8;SMALL(IF($d$2:$d$8=i$1;ROW($b$2:$b$8)-ROW($b$2)+1);ROWS(i$5:i5)));"")
enter with Ctrl+Shift+Enter than drag down to necessary range.
than using index in L5 : =IF(i5="";"";INDEX($e$2:$e$8;MATCH(i5;$b$2:$b$8;0);0)) and drag down. since the amount would be same for each person, even with different bill number, the index combined with match are sufficient for fulfill this.
i got the automation formula in col-i from mr. Aladin Akyurek and mr. PaddyD answer in other thread.
and the index and match is also from other thread.
the result is :
H | I | L | |
1 | criteria : | less | |
2 | count if "less": | 6 | |
3 | |||
4 | date | name | amount |
5 | mar-1 | hanson | (2000) |
6 | mar-1 | hanson | (2000) |
7 | mar-6 | tika | (3500) |
8 | mar-1 | hanson | (2000) |
9 | mar-8 | tika | (3500) |
10 | mar-8 | lulu | (500) |
<tbody>
</tbody>
the formula for automation is miraculous. and i have been using this for various other uses in other table.
but in this issue, i think the formula is need to be modified a bit, so that it could give only a unique result. (as shown above, the name hanson is repeated, where the desired result is only each unique name show up once)
i got an impression that if the column-I (name) has settled i could use
index + match for column-L, to get the amount
and use lookup for column-H to get the latest date payment from the person name (or i do wrong?).
but the problem is the column-I. could you guys suggest on something?
i'm sory if this is a double post where some one else is already asking about it some where. i have try to search a bit, with several keywords, and read a bit. but my eyes are already swirled @_@ :P