chesterrae
Board Regular
- Joined
- Dec 23, 2015
- Messages
- 51
Hi All,
Currently I have 10K+ rows of data which increase every month that's why I need a vba code that will return "Tier 2" and "Tier 3" in column (D) Tier.
Here are the conditions:
1) Tier 2, if there are 2 or more unique Order ID within the last 12 months per Account Name. (using Today() function)
2) Tier 3, if there are only 1 unique Order ID within the last 12 months per Account Name. (using Today() function).
3) Else Leave it blank.
Below is the sample data:
Excel 2007 32 bit
Thank you so much in advance!
Currently I have 10K+ rows of data which increase every month that's why I need a vba code that will return "Tier 2" and "Tier 3" in column (D) Tier.
Here are the conditions:
1) Tier 2, if there are 2 or more unique Order ID within the last 12 months per Account Name. (using Today() function)
2) Tier 3, if there are only 1 unique Order ID within the last 12 months per Account Name. (using Today() function).
3) Else Leave it blank.
Below is the sample data:
Excel 2007 32 bit
A | B | C | D | |
---|---|---|---|---|
1 | Order ID | Account Name | Order Date | Tier |
2 | 18JBP5008 | Robert Downey Jr | 10/1/2018 | Tier 3 |
3 | 18JBP5008 | Robert Downey Jr | 10/1/2018 | Tier 3 |
4 | 18JAK0336 | Chris Evans | 10/1/2018 | Tier 2 |
5 | 18JAK0336 | Chris Evans | 10/1/2018 | Tier 2 |
6 | 18JAK0335 | Chris Evans | 10/1/2018 | Tier 2 |
7 | 18JAP2322 | Chris Hemsworth | 1/1/2017 | |
8 | 18JAP2322 | Chris Hemsworth | 11/21/2017 | Tier 3 |
9 | 18JAP2322 | Chris Hemsworth | 12/21/2017 | Tier 3 |
10 | 18JAP2322 | Chris Hemsworth | 10/1/2018 | Tier 3 |
11 | 18JAN1058 | Scarlett Johansson | 10/1/2018 | Tier 3 |
12 | 18JDM5411 | Jeremy Renner | 8/2/2017 | |
13 | 18JDM5411 | Samuel Jackson | 8/10/2017 | |
14 | 18JDM5412 | Samuel Jackson | 10/2/2018 | Tier 3 |
15 | 18JBM3812 | Mark Ruffalo | 5/2/2017 | |
16 | 18JBM3813 | Mark Ruffalo | 6/3/2017 | |
17 | 18JBM3814 | Mark Ruffalo | 10/3/2018 | Tier 3 |
Sheet: Sheet1 |
Thank you so much in advance!
Last edited: