Skip to content

Commit

Permalink
Skip parallel scans if max_row == min_row
Browse files Browse the repository at this point in the history
  • Loading branch information
Mytherin committed Sep 4, 2024
1 parent ecfd645 commit 97cd982
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sqlite_db.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ bool SQLiteDB::GetRowIdInfo(const string &table_name, RowIdInfo &row_id_info) {
}
int64_t min_val = stmt.GetValue<int64_t>(0);
int64_t max_val = stmt.GetValue<int64_t>(1);
if (max_val < 0 || min_val < 0 || max_val < min_val) {
if (min_val < 0 || max_val <= min_val) {
return false;
}
static constexpr int64_t MAX_ROWS = 20000000000000;
Expand Down

0 comments on commit 97cd982

Please sign in to comment.