Extending by a function output
datatable(ids: dynamic)
[
dynamic([“value1”, “value2”])
]
| function(ids)
This above snippet works fine and returns a table
datatable(date: datetime, ids: dynamic)
[
datetime(2022-01-01), dynamic([“value1”, “value2”]),
datetime(2022-01-02), dynamic([“value3”, “value4”])
]
| extend outputs = function(ids)
This one however complains that extend expects a scalar and not table that the function returns
datatable(date: datetime, ids: dynamic)
[
datetime(2022-01-01), dynamic([“value1”, “value2”]),
datetime(2022-01-02), dynamic([“value3”, “value4”])
]
| extend outputs = toscalar(function(ids))
When using toscalar, ids cannot be referenced. Is there a workaround?
datatable(ids: dynamic)
[
dynamic([“value1”, “value2”])
]
| function(ids)This above snippet works fine and returns a tabledatatable(date: datetime, ids: dynamic)
[
datetime(2022-01-01), dynamic([“value1”, “value2”]),
datetime(2022-01-02), dynamic([“value3”, “value4”])
]
| extend outputs = function(ids)This one however complains that extend expects a scalar and not table that the function returnsdatatable(date: datetime, ids: dynamic)
[
datetime(2022-01-01), dynamic([“value1”, “value2”]),
datetime(2022-01-02), dynamic([“value3”, “value4”])
]
| extend outputs = toscalar(function(ids))When using toscalar, ids cannot be referenced. Is there a workaround? Read More