Feature/missing hana tests#3886
Conversation
thoniTUB
left a comment
There was a problem hiding this comment.
Hier werden viele Tests gelöscht, ist das korrekt?
| // Would prefer this to be `is not null`, but hana does not support that for fields | ||
| Field<String> isResolved = innerPrimaryColumn.as(IS_RESOLVED_ALIAS); |
There was a problem hiding this comment.
Warum kein boolean mehr und muss dann nicht auch das SQL Beispiel aus dem Kommentar angepasst werden?
There was a problem hiding this comment.
steht doch im Kommentar direkt drüber? Ich hab keine Syntax / konstrukt gefunden die für Hana funktioniert (Also einfach is not null meckert hana obwohl es eigentlich eine gültige Hana Expression ist). Ich schaue mal, ob ein case-when funktioniert.
There was a problem hiding this comment.
Habs über case-when gelöst. Danke für den Kommentar! 🙏
# Conflicts: # backend/src/test/resources/tests/aggregator/COUNT_QUARTERS_AGGREGATOR/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/COUNT_QUARTERS_AGGREGATOR/content.csv # backend/src/test/resources/tests/aggregator/DURATION_SUM_AGGREGATOR/DURATION_SUM.test.json # backend/src/test/resources/tests/aggregator/DURATION_SUM_DISTINCT_AGGREGATOR/DURATION_SUM.test.json # backend/src/test/resources/tests/aggregator/EVENT_DATE_AGGREGATOR/EVENT_DATE_AGGREGATOR_NO_RESTRICTION.test.json # backend/src/test/resources/tests/aggregator/EVENT_DATE_AGGREGATOR/EVENT_DATE_AGGREGATOR_RESTRICTION.test.json # backend/src/test/resources/tests/aggregator/EXISTS_AGGREGATOR/NUMBER.test.json # backend/src/test/resources/tests/aggregator/EXISTS_AGGREGATOR_OR/NUMBER.test.json # backend/src/test/resources/tests/aggregator/FIRST_AGGREGATOR/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/FLAGS_AGGREGATOR/FLAGS_AGGREGATOR.test.json # backend/src/test/resources/tests/aggregator/LAST_AGGREGATOR/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/MAPPED/DISTINCT/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/MAPPED/DISTINCT_MULTI/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/MAPPED/FIRST/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/MAPPED/FIRST_MULTI/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/QUARTER_AGGREGATOR/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/RANDOM_AGGREGATOR/SIMPLE_VIRTUAL_CONCEPT_Query.test.json # backend/src/test/resources/tests/aggregator/SUBSTRING/DISTINCT/MAPPED.test.json # backend/src/test/resources/tests/aggregator/SUBSTRING/DISTINCT/SIMPLE.test.json # backend/src/test/resources/tests/aggregator/SUBSTRING/DISTINCT_MULTI/MAPPED.test.json # backend/src/test/resources/tests/aggregator/SUBSTRING/FIRST/MAPPED.test.json # backend/src/test/resources/tests/aggregator/SUBSTRING/FIRST/SIMPLE.test.json
98afbcc to
59832b1
Compare
thoniTUB
left a comment
There was a problem hiding this comment.
habe nur kleinigkeiten angemerkt :)
| (this.functionProvider.getMinDateExpression()), | ||
| (this.functionProvider.getMaxDateExpression()), |
There was a problem hiding this comment.
| (this.functionProvider.getMinDateExpression()), | |
| (this.functionProvider.getMaxDateExpression()), | |
| this.functionProvider.getMinDateExpression(), | |
| this.functionProvider.getMaxDateExpression(), |
| Selects preprocessingSelects = Selects.builder() | ||
| .ids(tableContext.getIds()) | ||
| .validityDate(tableContext.getValidityDate()) | ||
| .validityDate(Optional.of(tableContext.getValidityDate())) |
There was a problem hiding this comment.
Wird das Optional-packing weiter unten sinnvoll? Optionals sollte man eher bei Rückgabewerten nutzen nicht als member oder Argument
| // Since coalesce makes Clickhouse certain, that the field is not nullable, it will do silly stuff with it down the line: | ||
| // missing values (for example in outer-joins) will be coerced to 0 = 01-01-1970, which is clearly not correct | ||
| // Therefore we tag the values as Nullable again to make Clickhouse show some respect |
| Field<Date> lowerBound = when(validityDateRange.getStart().lessThan(restriction.getStart()), restriction.getStart()) | ||
| .otherwise(validityDateRange.getStart()); | ||
|
|
||
| Field<Date> maxDate = getMinDateExpression(); // we want to add +1 day to the end date - except when it's the max date already |
There was a problem hiding this comment.
Wo ist das +1 von dem im Kommentar geschrieben ist?
| @Slf4j | ||
| public class ClickhouseSqlIntegrationTests extends IntegrationTests { | ||
|
|
||
| // SAP does not provide more than 1 image and on an update, the earlier image is deleted from dockerhub, thus latest tag is fine |
There was a problem hiding this comment.
Der Kommentar trifft nicht auf CH zu oder? Ich würde hier schon ein bestimmtes Image nehmen
| public class ClickhouseSqlIntegrationTests extends IntegrationTests { | ||
|
|
||
| // SAP does not provide more than 1 image and on an update, the earlier image is deleted from dockerhub, thus latest tag is fine | ||
| private final static DockerImageName IMAGE_TAGE = DockerImageName.parse("clickhouse/clickhouse-server"); |
There was a problem hiding this comment.
| private final static DockerImageName IMAGE_TAGE = DockerImageName.parse("clickhouse/clickhouse-server"); | |
| private final static DockerImageName IMAGE_TAG = DockerImageName.parse("clickhouse/clickhouse-server"); |
| 6,2012-01-01,"m" | ||
| 6,2012-01-01,"f" No newline at end of file |
There was a problem hiding this comment.
Ist das in den Datenbanken nicht deterministisch welcher wert genommen wird?
No description provided.