imply-cheddar commented on code in PR #13268:
URL: https://github.com/apache/druid/pull/13268#discussion_r1037579315
##########
processing/src/main/java/org/apache/druid/segment/ColumnarValueUnnestCursor.java:
##########
@@ -69,7 +94,11 @@ public ColumnSelectorFactory getColumnSelectorFactory()
@Override
public DimensionSelector makeDimensionSelector(DimensionSpec
dimensionSpec)
{
- throw new UnsupportedOperationException("Dimension selector not
applicable for column value selector");
+ if (!outputName.equals(dimensionSpec.getDimension())) {
+ return baseColumSelectorFactory.makeDimensionSelector(dimensionSpec);
+ }
+ throw new UnsupportedOperationException(
+ "Dimension selector not applicable for column value selector for
column " + outputName);
Review Comment:
More design nits:
1. We have a `UOE` that bundles `String.format` into the building of the
exception use that.
2. We encase interpolated values in `[]` to help differentiate things like
extra spaces.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]