mattyb149 commented on a change in pull request #4539:
URL: https://github.com/apache/nifi/pull/4539#discussion_r492195079
##########
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:
Also please update the Max Value Column property description to indicate
that it will be ignored if Custom ORDER BY Column is set
----------------------------------------------------------------
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:
[email protected]