On Fri, Apr 12, 2019 at 9:51 AM Paul Rogers <par0...@yahoo.com.invalid>
wrote:

> Hi All,
>
> The trick here, of course, is that Drill does not have the tuple concept
> of Python:
>
> zip([1, 2, 3], [4, 5, 6]) --> [(1, 4), (2, 5), (3, 6)]
>
>
> There is no good way in Drill, to represent the array of (1, 4), (2, 5)
> pairs. The best we can do is:
>
> * A map of two columns, with element names the same as the original array
> columns.
>

This sounds lovely to me.


> ... Also, since functions in Drill are typed, we'd need a "flatten2"
> function for all supported combinations of array types (int, int), (int,
> Varchar), (Varchar, int), (Varchar, Varchar), etc.
>
> Seems like there is an opportunity here to provide a better way to handle
> these kinds of vector (as in "array") operations.
>

The current situations is *definitely* a pain in the ass. It would be
*lovely* to have a simpler way to build UDFs even at the cost of some
performance.

Reply via email to