Forum Discussion

MSuser5's avatar
MSuser5
Helper III
2 years ago

based on continuous values result

Hi All,

 

I have daily customer data in that if value continuously 7 then consider as 1 please find below example kindly help me.

 

DateCustomer IDValue
01/10/2023111007
02/10/2023111007
03/10/2023111007
04/10/2023111007
05/10/2023111007
08/10/2023111007
09/10/2023111000
10/10/2023111000
11/10/2023111000
12/10/2023111000
15/10/2023111000
16/10/2023111000
17/10/2023111000
18/10/2023111000
19/10/2023111007
23/10/2023111007
24/10/2023111007
25/10/2023111007
26/10/2023111007
29/10/2023111000
30/10/2023111000
31/10/2023111000
   
01/10/20231110027
02/10/20231110027
17/10/20231110027
18/10/20231110027
19/10/20231110020
23/10/20231110020
24/10/20231110027
25/10/20231110020

 

now expected result like both customer values should be : (lets say first customer have continuous 7 values 2 times so result is 2 , and second customer have only one time continuous 7 value hence result will be 1.)

Customer IDResult
111002
1110021

5 Replies