You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/09/12 15:23:15 UTC
[GitHub] [arrow-datafusion] Ted-Jiang commented on a diff in pull request #3450: Add `InList` support for timestamp type. (#3449)
Ted-Jiang commented on code in PR #3450:
URL: https://github.com/apache/arrow-datafusion/pull/3450#discussion_r968557124
##########
datafusion/physical-expr/src/expressions/in_list.rs:
##########
@@ -1659,4 +1754,105 @@ mod tests {
Ok(())
}
+
+ #[test]
+ fn in_list_set_timestamp() -> Result<()> {
+ let schema = Schema::new(vec![Field::new(
+ "a",
+ DataType::Timestamp(TimeUnit::Microsecond, None),
+ true,
+ )]);
+ let a = TimestampMicrosecondArray::from(vec![
+ Some(1388588401000000000),
+ Some(1288588501000000000),
+ None,
+ ]);
+ let col_a = col("a", &schema)?;
+ let batch = RecordBatch::try_new(Arc::new(schema.clone()), vec![Arc::new(a)])?;
+
+ let mut list = vec![
+ lit(ScalarValue::TimestampMicrosecond(
+ Some(1388588401000000000),
+ None,
+ )),
+ lit(ScalarValue::TimestampMicrosecond(None, None)),
+ lit(ScalarValue::TimestampMicrosecond(
+ Some(1388588401000000001),
+ None,
+ )),
+ ];
+ for v in 1388588401000000001..(OPTIMIZER_INSET_THRESHOLD + 4) {
Review Comment:
Yes 😂
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org