SQL Selection (Rule Tree)

POST .../entity/sql_selection

This entity is unique in that the API will allow the user to create the entire rule tree in a single request instead of needing the create and link each parent/child object individually (it can still be done this way if the user chooses to do so). This is accomplished using the `children` list field. This is an abstract field that does not exists on the object itself, but rather defines the `parent_id` link, which will be handled by the API automatically.

To illustrate a complex example, the following request body could be used to create this rule structure as seen from the UI:

SQL Selection Rule Tree

Example Body Request

{
"fields": {
"facility_id": 1,
"sql_operator_id": 2,
"children": [
{
"column_name_id": 107,
"sql_operator_id": 5,
"column_value": "B"
},
{
"sql_operator_id": 1,
"children": [
{
"column_name_id": 1379,
"sql_operator_id": 7,
"column_value": "100"
},
{
"column_name_id": 35,
"sql_operator_id": 7,
"column_value": "50"
}
]
}
]
}
}