You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by xi...@apache.org on 2019/08/16 06:02:16 UTC
[incubator-pinot] branch update_selection_query_1 created (now
ecac2e0)
This is an automated email from the ASF dual-hosted git repository.
xiangfu pushed a change to branch update_selection_query_1
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git.
at ecac2e0 update column data type cast during inter merge
This branch includes the following new commits:
new ecac2e0 update column data type cast during inter merge
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org
[incubator-pinot] 01/01: update column data type cast during inter
merge
Posted by xi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
xiangfu pushed a commit to branch update_selection_query_1
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git
commit ecac2e0b57e3b583ee7827adc5a432562217a2c6
Author: Xiang Fu <fx...@gmail.com>
AuthorDate: Thu Aug 15 22:19:08 2019 -0700
update column data type cast during inter merge
---
.../pinot/core/operator/transform/TransformBlockDataFetcher.java | 5 +----
.../apache/pinot/core/query/selection/SelectionOperatorUtils.java | 5 ++++-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/TransformBlockDataFetcher.java b/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/TransformBlockDataFetcher.java
index 54e83be..b5c8d99 100644
--- a/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/TransformBlockDataFetcher.java
+++ b/pinot-core/src/main/java/org/apache/pinot/core/operator/transform/TransformBlockDataFetcher.java
@@ -199,9 +199,6 @@ class DictionaryBasedSVValueFetcher implements Fetcher {
}
public Serializable getValue(int docId) {
- if (_dataType.equals(FieldSpec.DataType.BYTES)) {
- return BytesUtils.toHexString(_dictionary.getBytesValue(_dictionaryIds[docId]));
- }
return (Serializable) _dictionary.get(_dictionaryIds[docId]);
}
}
@@ -337,4 +334,4 @@ class DictionaryBasedMVBytesValueFetcher implements Fetcher {
}
return values;
}
-}
\ No newline at end of file
+}
diff --git a/pinot-core/src/main/java/org/apache/pinot/core/query/selection/SelectionOperatorUtils.java b/pinot-core/src/main/java/org/apache/pinot/core/query/selection/SelectionOperatorUtils.java
index bbfa42f..0fe09a5 100644
--- a/pinot-core/src/main/java/org/apache/pinot/core/query/selection/SelectionOperatorUtils.java
+++ b/pinot-core/src/main/java/org/apache/pinot/core/query/selection/SelectionOperatorUtils.java
@@ -39,6 +39,7 @@ import org.apache.pinot.common.request.Selection;
import org.apache.pinot.common.request.SelectionSort;
import org.apache.pinot.common.response.ServerInstance;
import org.apache.pinot.common.response.broker.SelectionResults;
+import org.apache.pinot.common.utils.BytesUtils;
import org.apache.pinot.common.utils.DataSchema;
import org.apache.pinot.common.utils.DataTable;
import org.apache.pinot.core.common.DataSourceMetadata;
@@ -248,9 +249,11 @@ public class SelectionOperatorUtils {
dataTableBuilder.setColumn(i, ((Number) columnValue).doubleValue());
break;
case STRING:
- case BYTES: // BYTES are already converted to String for Selection, before reaching this layer.
dataTableBuilder.setColumn(i, ((String) columnValue));
break;
+ case BYTES:
+ dataTableBuilder.setColumn(i, BytesUtils.toHexString((byte[]) columnValue));
+ break;
// Multi-value column.
case INT_ARRAY:
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org