Commit d7f07de
authored
vortex-array: Attempt casting inner array to target for extensions (#7469)
## Summary
Getting
```
No CastKernel to cast canonical array vortex.ext from vortex.timestamp[ns, tz=UTC](i64) to i64
```
When running a datafusion query like:
```
SELECT cast(timestamp as bigint) as timestamp from table;
```
Where the timestamp array is a utc timestamp type column.
Since the inner array of a timestamp array is int64 already, all we
really need to do is try to attempt to cast the inner array of the
extension type to the target type. That's exactly what this PR does.
## Testing
Added a unit test.
Signed-off-by: Frederic Branczyk <fbranczyk@gmail.com>1 parent e4e7667 commit d7f07de
1 file changed
Lines changed: 26 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
21 | 23 | | |
22 | 24 | | |
23 | 25 | | |
| |||
51 | 53 | | |
52 | 54 | | |
53 | 55 | | |
| 56 | + | |
54 | 57 | | |
55 | 58 | | |
| 59 | + | |
56 | 60 | | |
| 61 | + | |
57 | 62 | | |
58 | 63 | | |
59 | 64 | | |
| |||
108 | 113 | | |
109 | 114 | | |
110 | 115 | | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
111 | 136 | | |
112 | 137 | | |
113 | 138 | | |
| |||
0 commit comments