diff --git a/dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/OrgUnitField.java b/dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/OrgUnitField.java index f16cbb92e06f..a6082dd3a33d 100644 --- a/dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/OrgUnitField.java +++ b/dhis-2/dhis-services/dhis-service-analytics/src/main/java/org/hisp/dhis/analytics/OrgUnitField.java @@ -223,7 +223,7 @@ private String ouQuote(String tableAlias, String col, boolean noColumnAlias) { + ((noColumnAlias) ? "" : " as " + col); } - return quote(tableAlias, col); + return sqlBuilder.quote(tableAlias, col); } @Override