queryverse / Query.jl

Query almost anything in julia

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TimeArray not a valid sink anymore?

louisponet opened this issue · comments

Hi All,
Title says it all. mwe:

using Query, DataFrames, TimeSeries, Dates

df = DataFrame(name=["John", "Sally", "Kirk"], age=[23., 42., 59.], children=[3,5,2], timestamp=[today() for i = 1:3])

x = @from i in df begin
           @select {i.name, i.age, Children=i.children, timestamp=i.timestamp}
           @collect TimeArray
end
# vs
x = @from i in df begin
           @select {i.name, i.age, Children=i.children, timestamp=i.timestamp}
           @collect DataFrame
end
TimeArray(x, timestamp=:timestamp)

This is a problem with TimeArray, it no longer has a constructor that accepts one argument that is a table.