github dolthub/dolt v1.34.2
1.34.2

latest releases: v1.43.13, v1.43.12, v1.43.11...
8 months ago

Merged PRs

dolt

go-mysql-server

  • 2331: fix NOT expression in conjunction with WHERE EXISTS(<subquery>)
    The analyzer rule unnest_exists_subqueries was accidentally dropping NOT expressions when hoisting subqueries from WHERE EXISTS... clauses.
    This should fix 8 sqllogictests.
    Correctness: #7510
  • 2330: Fix DISTINCT over DECIMALS
    There was another place where we were using hashstructure package, which does not hash decimal.Decimal types correctly.
    Switched to xxhash package, which is what we use everywhere else.
    Reusing solution from: dolthub/go-mysql-server#2279
    This will fix 1 sqllogictest.
  • 2329: expression.Div Micro Benchmarks
    There are going to be changes to our division behavior that impact both its accuracy and speed.
    This PR adds benchmarks to track the runtime improvements/degradations
  • 2326: Various Decimal Type Fixes
    This PR has a variety of fixes to have arithmetic operations (especially those involving decimals) behave more like MySQL.
    The logic for the Type() method for Arthmetic and Div is simpler, and better tested.
    When comparing Decimal results from division operations, MySQL has an internal Scale that is different than the Scale used when returning Decimal results for display.
    Here's a matrix displaying the resulting scale:
    (Ex: 1 / 3 = 0.333333333; scale 0 div scale 0 should return scale 9)
    image
    Additionally, this PR adds test for arithmetic operations over Datetime and Year types. There are still a some problems dealing with precision and parsing there...
    Note: I believe the division optimization where float division is preferred over decimal division for internal calculations may be causing problems. More testing is needed to see if it's possible to enable this without causing inaccuracies/precision loss.
    There are microbenchmarks measuring the performance of div expression, and it turns out these changes actually greatly improve the runtime.
    Correctness: #7484
    Fixes
  • 2323: SQLEXCEPTION proc handler
    We originally supported one type of procedure handler, NOT FOUND, which explicitly checked for an error when fetching from a cursor io.EOFs. The implementation for that handler would walk the entire BEGIN/END scope stack inside the Fetch call looking for a handler, execute the handler body, and then embed the scope height into a special return error. The error walked back up the callstack looking for the BEGIN/END block embedded in the error message.
    This PR:
    1. Refactors handlers to coordinate message passing in a centralized way. No metadata is embedded in FetchEOF, because each scope will explicitly compare its handlers to errors raised during execution within its BEGIN/END bounds. (FetchEOF is important because we differentiate between 3 different types of io.EOF in procedure loops).
    2. Add type/object support for representing specific signal handers.
    3. Add SQLEXCEPTION signal handling, which will trigger for any error type (other than io.EOF) that bubbles up during a BeginEndIter's execution.
      re: #7454
      Another thing I noticed is that some of our tests return nil for empty stored procedures when mysql returns ERROR 1329 (02000): No data - zero rows fetched, selected, or processed. https://github.com/dolthub/dolt/issues/new

Latency

Read Tests MySQL Dolt Multiple
covering_index_scan 2.11 2.81 1.3
groupby_scan 13.7 17.01 1.2
index_join 1.32 4.91 3.7
index_join_scan 1.25 2.14 1.7
index_scan 33.72 57.87 1.7
oltp_point_select 0.17 0.46 2.7
oltp_read_only 3.36 8.13 2.4
select_random_points 0.33 0.77 2.3
select_random_ranges 0.38 0.87 2.3
table_scan 34.33 57.87 1.7
types_table_scan 74.46 155.8 2.1
reads_mean_multiplier 2.1
Write Tests MySQL Dolt Multiple
oltp_delete_insert 5.67 5.99 1.1
oltp_insert 2.76 3.02 1.1
oltp_read_write 7.3 15.27 2.1
oltp_update_index 2.81 3.07 1.1
oltp_update_non_index 2.86 3.02 1.1
oltp_write_only 3.96 7.43 1.9
types_delete_insert 5.57 6.67 1.2
writes_mean_multiplier 1.4
TPC-C TPS Tests MySQL Dolt Multiple
tpcc-scale-factor-1 110.64 15.5 6.5
tpcc_tps_multiplier 6.5
Overall Mean Multiple 3.33

Don't miss a new dolt release

NewReleases is sending notifications on new releases.