Skip to content

Update DoltTable.ProjectedTags() to distinguish between no set projectedCols and zero projectedCols#10455

Merged
angelamayxie merged 14 commits intomainfrom
angela/leftlookupjoin
Feb 10, 2026
Merged

Update DoltTable.ProjectedTags() to distinguish between no set projectedCols and zero projectedCols#10455
angelamayxie merged 14 commits intomainfrom
angela/leftlookupjoin

Conversation

@angelamayxie
Copy link
Copy Markdown
Contributor

@angelamayxie angelamayxie commented Feb 9, 2026

fixes #10451

When getting ProjectedTags(), we were not distinguishing between when projectedCols was nil (meaning no projections are set so we should return all columns) and when projectedCols was an empty array of length 0 (meaning the table has been pruned to be zero columns but we still care about the number of rows), since in both cases, projectedCols would have a length of 0. This was causing LEFT OUTER JOINs that didn't project any left-side columns to not return the correct number of columns. This was fixed by checking for if projectedCols was nil instead (which is what we do in other functions like Projections() and HistoryTable.ProjectedTags()

Also some minor refactorings:

  • renamed getIta to getIndexedTableAccess
  • removed unused variables returned by getSourceKv

Test added in dolthub/go-mysql-server#3424

@coffeegoddd
Copy link
Copy Markdown
Contributor

@angelamayxie DOLT

comparing_percentages
100.000000 to 100.000000
version result total
eaeb2f9 ok 5937471
version total_tests
eaeb2f9 5937471
correctness_percentage
100.0

@coffeegoddd
Copy link
Copy Markdown
Contributor

@angelamayxie DOLT

comparing_percentages
100.000000 to 100.000000
version result total
a14c812 ok 5937471
version total_tests
a14c812 5937471
correctness_percentage
100.0

@coffeegoddd
Copy link
Copy Markdown
Contributor

@coffeegoddd DOLT

comparing_percentages
100.000000 to 100.000000
version result total
dfb7daf ok 5937471
version total_tests
dfb7daf 5937471
correctness_percentage
100.0

@angelamayxie angelamayxie changed the title left outer lookup join Update DoltTable.ProjectedTags() to distinguish between no set projectedCols and zero projectedCols Feb 9, 2026
@coffeegoddd
Copy link
Copy Markdown
Contributor

@angelamayxie DOLT

comparing_percentages
100.000000 to 100.000000
version result total
1a28801 ok 5937471
version total_tests
1a28801 5937471
correctness_percentage
100.0

@angelamayxie angelamayxie marked this pull request as ready for review February 10, 2026 00:26
@coffeegoddd
Copy link
Copy Markdown
Contributor

@angelamayxie DOLT

comparing_percentages
100.000000 to 100.000000
version result total
677d1f8 ok 5937471
version total_tests
677d1f8 5937471
correctness_percentage
100.0

Copy link
Copy Markdown
Contributor

@jycor jycor left a comment

Choose a reason for hiding this comment

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

LGTM

@jycor
Copy link
Copy Markdown
Contributor

jycor commented Feb 10, 2026

#benchmark-mini

@github-actions
Copy link
Copy Markdown

1 similar comment
@github-actions
Copy link
Copy Markdown

@coffeegoddd
Copy link
Copy Markdown
Contributor

@jycor DOLT

read_tests from_latency to_latency percent_change
covering_index_scan 0.55 0.54 -1.82
groupby_scan 10.27 10.09 -1.75
index_join 1.86 1.82 -2.15
index_join_scan 1.34 1.34 0.0
index_scan 22.28 22.28 0.0
oltp_point_select 0.27 0.27 0.0
oltp_read_only 5.28 5.28 0.0
select_random_points 0.54 0.54 0.0
select_random_ranges 0.55 0.55 0.0
table_scan 22.28 22.28 0.0
types_table_scan 66.84 68.05 1.81
write_tests from_latency to_latency percent_change
oltp_delete_insert 6.32 6.32 0.0
oltp_insert 3.07 3.07 0.0
oltp_read_write 11.45 11.45 0.0
oltp_update_index 3.19 3.19 0.0
oltp_update_non_index 3.13 3.13 0.0
oltp_write_only 6.09 6.09 0.0
types_delete_insert 6.91 6.79 -1.74

@coffeegoddd
Copy link
Copy Markdown
Contributor

@jycor DOLT

test_name from_latency_p95 to_latency_p95 percent_change
tpcc-scale-factor-1 61.08 61.08 0.0
test_name from_server_name from_server_version from_tps to_server_name to_server_version to_tps percent_change
tpcc-scale-factor-1 dolt f729910 37.8 dolt 677d1f8 37.58 -0.58

@coffeegoddd
Copy link
Copy Markdown
Contributor

@angelamayxie DOLT

comparing_percentages
100.000000 to 100.000000
version result total
3366191 ok 5937471
version total_tests
3366191 5937471
correctness_percentage
100.0

@angelamayxie angelamayxie merged commit 73a4525 into main Feb 10, 2026
23 of 24 checks passed
@angelamayxie angelamayxie deleted the angela/leftlookupjoin branch February 10, 2026 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect indexes in left outer lookup join

3 participants