You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by pe...@apache.org on 2022/01/10 16:07:58 UTC

[pulsar] 10/16: Fix time field use error (#12249)

This is an automated email from the ASF dual-hosted git repository.

penghui pushed a commit to branch branch-2.9
in repository https://gitbox.apache.org/repos/asf/pulsar.git

commit a27fb57a183649eede83da50af5bc9c859535367
Author: liuchangqing <ca...@126.com>
AuthorDate: Thu Jan 6 13:19:24 2022 +0800

    Fix time field use error (#12249)
    
    * Fix time field use error
    
    * rebuid
    
    Co-authored-by: liu.changqing <ch...@kingdee.com>
    (cherry picked from commit 793dd910fc17b0e149f4b554b54cad55ca5bc479)
---
 .../src/main/java/org/apache/pulsar/sql/presto/PulsarRecordCursor.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarRecordCursor.java b/pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarRecordCursor.java
index 99be9f9..d839e05 100644
--- a/pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarRecordCursor.java
+++ b/pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarRecordCursor.java
@@ -580,7 +580,7 @@ public class PulsarRecordCursor implements RecordCursor {
                     currentRowValuesMap.put(columnHandle, longValueProvider(this.partition));
                 } else if (PulsarInternalColumn.EVENT_TIME.getName().equals(columnHandle.getName())) {
                     currentRowValuesMap.put(columnHandle, PulsarFieldValueProviders.timeValueProvider(
-                            this.currentMessage.getEventTime(), this.currentMessage.getPublishTime() == 0));
+                            this.currentMessage.getEventTime(), this.currentMessage.getEventTime() == 0));
                 } else if (PulsarInternalColumn.PUBLISH_TIME.getName().equals(columnHandle.getName())) {
                     currentRowValuesMap.put(columnHandle, PulsarFieldValueProviders.timeValueProvider(
                             this.currentMessage.getPublishTime(), this.currentMessage.getPublishTime() == 0));