Debian Codegraph @

test/command/suite/select/columns/window_function/window_sum/ascending.expected

raw
1 table_create Items TABLE_HASH_KEY ShortText
2 [[0,0.0,0.0],true]
3 column_create Items price COLUMN_SCALAR UInt32
4 [[0,0.0,0.0],true]
5 load --table Items
6 [
7 {"_key": "item1", "price": 666},
8 {"_key": "item2", "price": 999},
9 {"_key": "item3", "price": 777},
10 {"_key": "item4", "price": 111},
11 {"_key": "item5", "price": 333},
12 {"_key": "item6", "price": 222}
13 ]
14 [[0,0.0,0.0],6]
15 select Items --columns[sum].stage initial --columns[sum].value 'window_sum(price)' --columns[sum].type UInt32 --columns[sum].window.sort_keys price --output_columns '_key, price, sum' --sort_keys price
16 [
17 [
18 0,
19 0.0,
20 0.0
21 ],
22 [
23 [
24 [
25 6
26 ],
27 [
28 [
29 "_key",
30 "ShortText"
31 ],
32 [
33 "price",
34 "UInt32"
35 ],
36 [
37 "sum",
38 "UInt32"
39 ]
40 ],
41 [
42 "item4",
43 111,
44 111
45 ],
46 [
47 "item6",
48 222,
49 333
50 ],
51 [
52 "item5",
53 333,
54 666
55 ],
56 [
57 "item1",
58 666,
59 1332
60 ],
61 [
62 "item3",
63 777,
64 2109
65 ],
66 [
67 "item2",
68 999,
69 3108
70 ]
71 ]
72 ]
73 ]