summaryrefslogtreecommitdiff
path: root/butler/config.json
blob: 9a456a3eea69f787ed7d058a811a2587e830aec5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{
    "1+2": {
        "source": [
            "dmp202021_1n_b",
            "dmp202021_1s",
            "dmp202021_2se",
            "dmp202021_2sw",
            "dmp202021_2ne",
            "dmp202021_2nw"
        ],
        "output": "dmp202021_b_0"
    },
    "1": {
        "source": [
            "dmp202021_1n_b",
            "dmp202021_1s"
        ],
        "output": "dmp202021_b_1"
    },
    "2": {
        "source": [
            "dmp202021_2sw",
            "dmp202021_2ne",
            "dmp202021_2nw",
            "dmp202021_2se"
        ],
        "output": "dmp202021_b_2"
    },
    "__groups": {
        "dmp202021_e": "E",
        "dmp202021_1s": "S",
        "dmp202021_1n_b": "N",
        "dmp202021_2se": "SE",
        "dmp202021_2sw": "SW",
        "dmp202021_2ne": "NE",
        "dmp202021_2nw": "NW"
    },
    "__queries": {
        "dmp202021_1n_b": [
            "UPDATE _matches SET mtitle = '--' WHERE rnd < 6;",
            "UPDATE _segments SET openN = 0, openS = 0, openW = 0, openE = 0, closeN = 0, closeS = 0, closeW = 0, closeE = 0, towel = 1 WHERE rnd < 6;"
        ],
        "dmp202021_2se": [
            "INSERT INTO _teams(id, bye) VALUES(15, 2),(16, 2);",
            "INSERT INTO _matches(rnd, tabl, homet, visit, mtitle) SELECT rnd, 8, 15, 16, '--' FROM rounds WHERE rnd < 14;",
            "INSERT INTO _matches(rnd, tabl, homet, visit, mtitle) SELECT 14, id, id, id+8, '--' FROM teams WHERE id < 9;",
            "INSERT INTO _matches(rnd, tabl, homet, visit, mtitle) SELECT 15, id, id, id+8, '--' FROM teams WHERE id < 9;",
            "INSERT INTO _segments(rnd, segment, tabl, homet, visit, towel) SELECT rnd, 1, 8, 15, 16, 1 FROM rounds;",
            "INSERT INTO _segments(rnd, segment, tabl, homet, visit, towel) SELECT rnd, 2, 8, 15, 16, 1 FROM rounds;"
        ]
    }
}