Skip to content

Conversation

@jnsrnhld
Copy link
Collaborator

@jnsrnhld jnsrnhld commented Nov 13, 2025

Das reverted alles, was bisher die nicht korrekt funktionierende Negation implementier hat.
Nur bzgl. invertiertes Validity Date bin ich mir noch unsicher - brauchen wir das irgendwie? Ich habe die entsprechende Stelle nochmal kommentiert.

.withNegation(false);

QueryStep queryStep = converted.getLastConvertedStep();
if (negationNode.getDateAction() != DateAggregationAction.NEGATE) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Die Stelle hier meine ich. Ggf. müssten wir darüber nochmal sprechen.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich verstehe die Frage nicht ganz. Geht die negierte Datumsaggregation für dateMode=Logical jetzt nicht mehr?

Copy link
Collaborator

@awildturtok awildturtok left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sieht soweit gut aus, muss mir noch das SQL anschauen.

Comment on lines 79 to 81
if (queriesToJoin.stream().anyMatch(QueryStep::isNegate)) {
List<QueryStep> nonNegateSteps = queriesToJoin.stream().filter(Predicate.not(QueryStep::isNegate)).toList();
List<QueryStep> negateSteps = queriesToJoin.stream().filter(QueryStep::isNegate).toList();
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hier wäre ein partitioningBy schöner denke ich.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also

partitioned = queriesToJoin.partitionBy(isNegate);

if(!partitioned.get(true).isEmpty()){
     ...
}


return QueryStep.builder()
.cteName(context.getNameGenerator().joinedNodeName(logicalOperation) + NEGATED_CTE_SUFFIX)
.selects(nonNegateJoined.getQualifiedSelects())
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Die selects von negated werden auch ausgegeben.

.withNegation(false);

QueryStep queryStep = converted.getLastConvertedStep();
if (negationNode.getDateAction() != DateAggregationAction.NEGATE) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ich verstehe die Frage nicht ganz. Geht die negierte Datumsaggregation für dateMode=Logical jetzt nicht mehr?

@jnsrnhld
Copy link
Collaborator Author

@awildturtok Der hier

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants