Map function in array with conditions, not keys

Hi everyone,

I have a case like this. I have a HTTP call where I’m querying back an array of rows from a Glide (Glide Apps) table.

The result can look like the image above, I’m gonna copy it under:

[
            {
                "rows": [
                    {
                        "$rowIndex": "W",
                        "$rowID": "28XOIDjKRT6Dun0WbYc-YA",
                        "GZBli": "Event 2",
                        "7Wunh": "New",
                        "af5TD": "2023-08-15T20:26:09.029Z"
                    },
                    {
                        "$rowIndex": "W3",
                        "$rowID": "3ZANZFHcTc6E8eWzn2Rn.w",
                        "GZBli": "Event 5",
                        "7Wunh": "New",
                        "af5TD": "2023-06-15T20:26:22.407Z"
                    },
                    {
                        "$rowIndex": "V",
                        "$rowID": "3FO3ynuWQ8SkhBUAE16khg",
                        "GZBli": "Event 1",
                        "7Wunh": "Upcoming",
                        "af5TD": "2023-07-17T12:00:00.000Z"
                    },
                    {
                        "$rowIndex": "W1",
                        "$rowID": "pUXNwSGBS8OS0H4ouwlI.g",
                        "GZBli": "Event 3",
                        "7Wunh": "Upcoming",
                        "af5TD": "2023-07-02T12:00:00.000Z"
                    },
                    {
                        "$rowIndex": "W2",
                        "$rowID": "j9fo3j1pQLyxvDcF2N1g1g",
                        "GZBli": "Event 4",
                        "7Wunh": "New",
                        "af5TD": "2023-07-04T12:00:00.000Z"
                    }
                ]
            }
        ],
        "fileSize": 620
    }
]

Now, the “7Wunh” column with “New” and “Upcoming” values are random values I attach to the row to test the function. I can grab a list of upcoming event names, and new event names by a map function.

However, in reality, what we need is the ability to filter the “af5TD” column.

Is there a way to not use a filter, and be able to get a list of event names, where the timestamp is in the future, using just array/text functions?

There is no straight way to do it besides the iterator and array aggregator functions. It will consume two operations so it should be good enough for what you want to do.

2 Likes