You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "walterddr (via GitHub)" <gi...@apache.org> on 2023/06/02 00:12:40 UTC

[GitHub] [pinot] walterddr commented on a diff in pull request #10790: [multistage]: Changes for supporting Json scalar functions.

walterddr commented on code in PR #10790:
URL: https://github.com/apache/pinot/pull/10790#discussion_r1213791510


##########
pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/LeafStageTransferableBlockOperator.java:
##########
@@ -308,13 +309,16 @@ private static boolean inOrder(int[] columnIndices) {
    * @param dataSchema data schema desired for the row.
    * @return canonicalize row.
    */
-  private static Object[] canonicalizeRow(Object[] row, DataSchema dataSchema) {
+  private static Object[] canonicalizeRow(Object[] row, DataSchema dataSchema, DataSchema resultSchema) {
     Object[] resultRow = new Object[row.length];
     for (int colId = 0; colId < row.length; colId++) {
       Object value = row[colId];
       if (value != null) {
         if (dataSchema.getColumnDataType(colId) == DataSchema.ColumnDataType.OBJECT) {
           resultRow[colId] = value;
+        } else if (dataSchema.getColumnDataType(colId) == DataSchema.ColumnDataType.BYTES) {
+          dataSchema.getColumnDataTypes()[colId] = resultSchema.getColumnDataType(colId);

Review Comment:
   i don't rightfully know. we should add tests against Postgres behavior and see what's expected and modify our behavior accordingly



-- 
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: commits-unsubscribe@pinot.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org