mapleFU commented on PR #37793:
URL: https://github.com/apache/arrow/pull/37793#issuecomment-1726987962

   @bkietz I've write a test about Timestamp in my local machine:
   
   ```c++
   TEST_P(TestParquetFileFormatScan, 
PredicatePushdownRowGroupFragmentsUsingTimestampColumn) {
     auto table = TableFromJSON(schema({field("t", time32(TimeUnit::SECOND))}),
                                {
                                    R"([{"t": 1}])",
                                    R"([{"t": 2}, {"t": 3}])",
                                });
     TableBatchReader table_reader(*table);
     
SCOPED_TRACE("TestParquetFileFormatScan.PredicatePushdownRowGroupFragmentsUsingTimestampColumn");
     ASSERT_OK_AND_ASSIGN(
         auto buffer,
         ParquetFormatHelper::Write(
             &table_reader, 
ArrowWriterProperties::Builder().store_schema()->build()));
     auto source = std::make_shared<FileSource>(buffer);
     SetSchema({field("t", time32(TimeUnit::SECOND))});
     ASSERT_OK_AND_ASSIGN(auto fragment, format_->MakeFragment(*source));
   
     auto expr = equal(field_ref("t"), literal(::arrow::Time32Scalar(1, 
TimeUnit::SECOND)));
     CountRowGroupsInFragment(fragment, {0}, expr);
   }
   ```
   
   The test failed because:
   
   ```
    Function 'equal' has no kernel matching input types (time32[s], time32[ms])
   ```
   
   1. Parquet doesn't have second in parquet, so it was convert to store as `ms`
   2. In our expr system, we use `equal(time32[s], time32[ms])`
   
   I'll separate a pr for this. 


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to