ELEMENT_OF
This page describes the ELEMENT_OF function in Lenses SQL.
ELEMENT_OF(array, index)
Return the element of array
at index.
Available in:
Sample code:
USE `kafka`;
SELECT ELEMENT_OF(products, 2)
FROM orders-events
LIMIT 1;
Output:
{
"value": {
"ELEMENT_OF": {
"product_id": "d3f085e0-c049-4e8b-9dd9-ea3ae124720b",
"quantity": 1
}
}
}