ibmy
Board Regular
- Joined
- Mar 4, 2020
- Messages
- 134
- Office Version
- 2016
- Platform
- Windows
Hi,
Explanation in visual :
Explanation in text:
1) Keep assign "1" in column E if "A" value less than or same as starting "A" value AND "B" value more than or same as starting "B" value.
2) Stop assign "1" in column E if "A" value more than starting "A" value OR "B" value less than starting "B" value OR both happened.
Prefer VBA code solution but if formula solution can get 250k row data get result faster, dont matter.
Explanation in visual :
Explanation in text:
1) Keep assign "1" in column E if "A" value less than or same as starting "A" value AND "B" value more than or same as starting "B" value.
2) Stop assign "1" in column E if "A" value more than starting "A" value OR "B" value less than starting "B" value OR both happened.
less more.xlsx | |||||||
---|---|---|---|---|---|---|---|
C | D | E | F | G | |||
1 | "A" | "B" | Result | explanation: | |||
2 | 1.19048 | 1.19044 | Start here, "A" number : 1.19048 , "B" number : 1.19044 | ||||
3 | 1.19045 | 1.19044 | 1 | ||||
4 | 1.19046 | 1.19044 | 1 | ||||
5 | 1.19046 | 1.19045 | 1 | ||||
6 | 1.19047 | 1.19046 | 1 | ||||
7 | 1.19048 | 1.19043 | "B" number less than 1.19044. New "A" number : 1.19048 , "B" number : 1.19043 | ||||
8 | 1.19049 | 1.19045 | "A" number more than 1.19048. New "A" number : 1.19049, "B" number : 1.19045 | ||||
9 | 1.19048 | 1.19046 | 1 | ||||
10 | 1.19048 | 1.19047 | 1 | ||||
11 | 1.19050 | 1.19042 | "A" number more than 1.19049 and "B" number less than 1.19045. New "A" number : 1.19050, "B" number : 1.19042 | ||||
12 | 1.19049 | 1.19045 | 1 | ||||
13 | 1.19048 | 1.19047 | 1 | ||||
14 | 1.19046 | 1.19044 | 1 | ||||
15 | 1.19047 | 1.19045 | 1 | ||||
16 | 1.19047 | 1.19046 | 1 | ||||
17 | 1.19053 | 1.19044 | "A" number more than 1.19050. New "A" number : 1.19053, "B" number : 1.19044 | ||||
18 | 1.19047 | 1.19044 | 1 | ||||
19 | 1.19050 | 1.19045 | 1 | ||||
20 | 1.19044 | 1.19039 | "B" number less than 1.19044. New "A" number : 1.19044 , "B" number : 1.19039 | ||||
21 | 1.19045 | 1.19028 | "A" number more than 1.19044 and "B" number less than 1.19039. New "A" number : 1.19045, "B" number : 1.19028 | ||||
22 | 1.19060 | 1.19027 | "A" number more than 1.19045. New "A" number : 1.19060, "B" number : 1.19027 | ||||
Sheet5 |
Prefer VBA code solution but if formula solution can get 250k row data get result faster, dont matter.