Hi, Ron

I want to parse the function(unix_timestamp, from_unixtime etc.) during the task runtime.

Best regards,
Xianxun

---- Replied Message ----
From liu ron<ron9....@gmail.com>
Date 09/8/2023 10:01
To user@flink.apache.org<user@flink.apache.org>
Subject Re: Serialize and Parse ResolvedExpression
Hi, Xianxun

Do you mean the unix_timestamp() is parsed to the time when the query is compiled in streaming mode?

Best,
Ron

Xianxun Ye <yesorno828...@gmail.com> 于2023年9月7日周四 18:19写道:
Hi Team,

I want to Serialize the ResolvedExpression to String or byte[] and transmit it into LookupFunction, and parse it back to ResolvedExpression in the LookupFunction.
For my case:
Select * from left_stream as s join dim_table for system_time as of s.proc_time as d on s.id=d.id where d.ptcast(from_unixtime(unix_timestamp()-3*60*60,'yyyy-MM-dd-HH') as string)

The filter will be pushed down to lookupFunction, and I hope that when a task is failover, the time to be filtered is calculated based on the failover time, not the time when the task is first started. 
For example: 
    9.1 10:00:00 launch the task; // the lookupFunction will load the data after 9.1 7:00:00
    9.5 10:00:00 the task failover; // hope loading the data after 9.5 7:00:00

Is there an approach to make ResolvedExpression serializable?


Best regards,

Xianxun

Reply via email to