{
  "info": "---- ?? tarkoittaa epäselvää",
  "name": "mainlevel",
  "query": [
    ["_fo_SEL_USE", ["Into_current_selection", ""]],

    ["wo_OPEN_QRY", ["true"]],

    ["_txt", "=", [["_fld_Name4DLong", ["wo_production_lot"]], "+", "=", "+", ["_fld_Name4DLong", ["wo_parent_production_lot"]]]],
    ["_long", "=", ["_qry_Formula", ["wo_tbl", "_txt", "true"]]],
    ["_set_CREATE", ["wo_tbl", "wo_MainLevelQuerySet1"]],

    ["_fo_SEL_USE", ["Into_current_selection", ""]],
    ["_txt", "=", ""],
    ["_qry_Fld", ["0", ["wo_parent_production_lot", "=", "_txt"], "", "true"]],
    ["set_CREATE", ["wo_tbl", "wo_MainLevelQuerySet2"]],

    ["_set_UNION", ["wo_tbl", "wo_MainLevelQuerySet1", "wo_MainLevelQuerySet2", "wo_MainLevelQuerySet1"]],
    ["_set_USE", ["wo_tbl", "wo_MainLevelQuerySet1"]],

    ["_set_CLEAR", ["wo_tbl", "wo_MainLevelQuerySet1"]],
    ["_set_CLEAR", ["wo_tbl", "wo_MainLevelQuerySet2"]]
  ]
}
