You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2020/09/24 06:23:39 UTC

[GitHub] [nifi] KuKuDeCheng commented on a change in pull request #4539: NIFI-7824:GenerateTableFetch Improvement

KuKuDeCheng commented on a change in pull request #4539:
URL: https://github.com/apache/nifi/pull/4539#discussion_r494065190



##########
File path: nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/GenerateTableFetch.java
##########
@@ -511,7 +511,7 @@ public void onTrigger(final ProcessContext context, final ProcessSessionFactory
                         whereClause = maxValueClauses.isEmpty() ? "1=1" : StringUtils.join(maxValueClauses, " AND ");
                         Long offset = partitionSize == 0 ? null : i * partitionSize + (useColumnValsForPaging ? minValueForPartitioning : 0);
                         // Don't use an ORDER BY clause if there's only one partition
-                        final String orderByClause = partitionSize == 0 ? null : (maxColumnNames.isEmpty() ? customOrderByColumn : maxColumnNames);
+                        final String orderByClause = partitionSize == 0 ? null : (StringUtils.isNotEmpty(customOrderByColumn) ? customOrderByColumn : maxColumnNames);

Review comment:
       Thank you for reminding me. I will change the description of `Custom ORDER BY Column`. And I think we do not need to change `Max Value Column` property description, it's a common property used by different processors, and when we use  `Custom ORDER BY Column`, we see the description and we will know what will happen.




----------------------------------------------------------------
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.

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