duckdb 0.3.2-dev337.0 → 0.3.2-dev345.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.2-dev337.0",
4
+ "version": "0.3.2-dev345.0",
5
5
  "description": "DuckDB node.js API",
6
6
  "gypfile": true,
7
7
  "dependencies": {
package/src/duckdb.cpp CHANGED
@@ -90022,6 +90022,8 @@ void InstrFun::RegisterFunction(BuiltinFunctions &set) {
90022
90022
  set.AddFunction(instr);
90023
90023
  instr.name = "strpos";
90024
90024
  set.AddFunction(instr);
90025
+ instr.name = "position";
90026
+ set.AddFunction(instr);
90025
90027
  }
90026
90028
 
90027
90029
  } // namespace duckdb
@@ -117137,6 +117139,8 @@ struct CSEReplacementState {
117137
117139
  column_binding_map_t<idx_t> column_map;
117138
117140
  //! The set of expressions of the resulting projection
117139
117141
  vector<unique_ptr<Expression>> expressions;
117142
+ //! Cached expressions that are kept around so the expression_map always contains valid expressions
117143
+ vector<unique_ptr<Expression>> cached_expressions;
117140
117144
  };
117141
117145
 
117142
117146
  void CommonSubExpressionOptimizer::VisitOperator(LogicalOperator &op) {
@@ -117212,6 +117216,8 @@ void CommonSubExpressionOptimizer::PerformCSEReplacement(unique_ptr<Expression>
117212
117216
  // has not been pushed yet: push it
117213
117217
  node.column_index = state.expressions.size();
117214
117218
  state.expressions.push_back(move(*expr_ptr));
117219
+ } else {
117220
+ state.cached_expressions.push_back(move(*expr_ptr));
117215
117221
  }
117216
117222
  // replace the original expression with a bound column ref
117217
117223
  *expr_ptr = make_unique<BoundColumnRefExpression>(alias, type,
@@ -147142,7 +147148,7 @@ BindResult ExpressionBinder::BindFunction(FunctionExpression &function, ScalarFu
147142
147148
  unique_ptr<Expression> result =
147143
147149
  ScalarFunction::BindScalarFunction(context, *func, move(children), error, function.is_operator);
147144
147150
  if (!result) {
147145
- throw BinderException(binder.FormatError(function, error));
147151
+ return BindResult(binder.FormatError(function, error));
147146
147152
  }
147147
147153
  return BindResult(move(result));
147148
147154
  }
package/src/duckdb.hpp CHANGED
@@ -10,8 +10,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
10
10
 
11
11
  #pragma once
12
12
  #define DUCKDB_AMALGAMATION 1
13
- #define DUCKDB_SOURCE_ID "c69ecbf73"
14
- #define DUCKDB_VERSION "0.3.2-dev337"
13
+ #define DUCKDB_SOURCE_ID "89fff31ff"
14
+ #define DUCKDB_VERSION "0.3.2-dev345"
15
15
  //===----------------------------------------------------------------------===//
16
16
  // DuckDB
17
17
  //