Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
For the time column
24
201
11
43
21
57
0
121
22
4
159
0
2
46
Need to group them into Time interval:
15 - 120min
120 - 240min
240 - 360min
each interval is 120min
I believe it should still work with thousands or million of rows of data. I am not sure I understand your concern.
Hi,
another solution could be:
table1:
LOAD *,
If(time<15,Dual('<15min',14),If(time>=15 and time<120,Dual('15 - 120min',15),Dual(Replace(Class(time,120),'<= x <','-')&'min',Class(time,120)))) as [time interval];
LOAD Floor(Rand()*500) as time
AutoGenerate 30;
hope this helps
regards
Marco
I see there are 5 rows of 15 - 120 min, is there a way to group it together and replace the time column as 5 and a unique time interval as 15 - 120min?
You mean like
count([time interval])
?
Yes, of course.
Regards
Marco
example:
hope this helps
regards
Marco
Is there a way to open your file? I'm using personal edition
create new qvw, copy my script and paste it using the script editor.
reload, create a chart straight table using time interval as dimension and count([time interval]) as expression.
regards
Marco
How come the count all total as 30?
it's the sum
2+6+5+11+5+1 = 30
hope this helps
regards
Marco
I was trying to achieve the above, as you notice the 2 boxes on the right all total 1000 (in your eg should be 30) and the time interval 15 - 120min is both 107?