duckdb 0.3.3-dev839.0 → 0.3.3-dev841.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "duckdb",
3
3
  "main": "./lib/duckdb.js",
4
- "version": "0.3.3-dev839.0",
4
+ "version": "0.3.3-dev841.0",
5
5
  "description": "DuckDB node.js API",
6
6
  "gypfile": true,
7
7
  "dependencies": {
package/src/duckdb.cpp CHANGED
@@ -128204,12 +128204,30 @@ bool Pipeline::GetProgressInternal(ClientContext &context, PhysicalOperator *op,
128204
128204
  current_percentage = get.function.table_scan_progress(context, get.bind_data.get());
128205
128205
  return true;
128206
128206
  }
128207
- //! If the table_scan_progress is not implemented it means we don't support this function yet in the progress
128208
- //! bar
128207
+ // If the table_scan_progress is not implemented it means we don't support this function yet in the progress
128208
+ // bar
128209
128209
  return false;
128210
128210
  }
128211
- default:
128212
- return false;
128211
+ // If it is not a table scan we go down on all children until we reach the leaf operators
128212
+ default: {
128213
+ vector<idx_t> progress;
128214
+ vector<idx_t> cardinality;
128215
+ double total_cardinality = 0;
128216
+ current_percentage = 0;
128217
+ for (auto &op_child : op->children) {
128218
+ double child_percentage = 0;
128219
+ if (!GetProgressInternal(context, op_child.get(), child_percentage)) {
128220
+ return false;
128221
+ }
128222
+ progress.push_back(child_percentage);
128223
+ cardinality.push_back(op_child->estimated_cardinality);
128224
+ total_cardinality += op_child->estimated_cardinality;
128225
+ }
128226
+ for (size_t i = 0; i < progress.size(); i++) {
128227
+ current_percentage += progress[i] * cardinality[i] / total_cardinality;
128228
+ }
128229
+ return true;
128230
+ }
128213
128231
  }
128214
128232
  }
128215
128233
  // LCOV_EXCL_STOP
package/src/duckdb.hpp CHANGED
@@ -11,8 +11,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
11
11
  #pragma once
12
12
  #define DUCKDB_AMALGAMATION 1
13
13
  #define DUCKDB_AMALGAMATION_EXTENDED 1
14
- #define DUCKDB_SOURCE_ID "4d7d868d1"
15
- #define DUCKDB_VERSION "v0.3.3-dev839"
14
+ #define DUCKDB_SOURCE_ID "e59fa8bce"
15
+ #define DUCKDB_VERSION "v0.3.3-dev841"
16
16
  //===----------------------------------------------------------------------===//
17
17
  // DuckDB
18
18
  //