duckdb 0.6.2-dev572.0 → 0.6.2-dev576.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
@@ -2,7 +2,7 @@
2
2
  "name": "duckdb",
3
3
  "main": "./lib/duckdb.js",
4
4
  "types": "./lib/duckdb.d.ts",
5
- "version": "0.6.2-dev572.0",
5
+ "version": "0.6.2-dev576.0",
6
6
  "description": "DuckDB node.js API",
7
7
  "gypfile": true,
8
8
  "dependencies": {
package/src/duckdb.cpp CHANGED
@@ -194958,6 +194958,7 @@ public:
194958
194958
  } // namespace duckdb
194959
194959
 
194960
194960
 
194961
+
194961
194962
  namespace duckdb {
194962
194963
 
194963
194964
  unique_ptr<BoundTableRef> Binder::Bind(BaseTableRef &ref) {
@@ -195013,14 +195014,17 @@ unique_ptr<BoundTableRef> Binder::Bind(BaseTableRef &ref) {
195013
195014
  auto table_name = ref.schema_name.empty() ? ref.table_name : (ref.schema_name + "." + ref.table_name);
195014
195015
  // table could not be found: try to bind a replacement scan
195015
195016
  auto &config = DBConfig::GetConfig(context);
195016
- for (auto &scan : config.replacement_scans) {
195017
- auto replacement_function = scan.function(context, table_name, scan.data.get());
195018
- if (replacement_function) {
195019
- replacement_function->alias = ref.alias.empty() ? ref.table_name : ref.alias;
195020
- replacement_function->column_name_alias = ref.column_name_alias;
195021
- return Bind(*replacement_function);
195017
+ if (context.config.use_replacement_scans) {
195018
+ for (auto &scan : config.replacement_scans) {
195019
+ auto replacement_function = scan.function(context, table_name, scan.data.get());
195020
+ if (replacement_function) {
195021
+ replacement_function->alias = ref.alias.empty() ? ref.table_name : ref.alias;
195022
+ replacement_function->column_name_alias = ref.column_name_alias;
195023
+ return Bind(*replacement_function);
195024
+ }
195022
195025
  }
195023
195026
  }
195027
+
195024
195028
  // we still didn't find the table
195025
195029
  if (GetBindingMode() == BindingMode::EXTRACT_NAMES) {
195026
195030
  // if we are in EXTRACT_NAMES, we create a dummy table ref