duckdb 0.4.1-dev464.0 → 0.4.1-dev484.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/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 "f5be5d58a"
15
- #define DUCKDB_VERSION "v0.4.1-dev464"
14
+ #define DUCKDB_SOURCE_ID "02c61edbb"
15
+ #define DUCKDB_VERSION "v0.4.1-dev484"
16
16
  //===----------------------------------------------------------------------===//
17
17
  // DuckDB
18
18
  //
@@ -20819,6 +20819,7 @@ public:
20819
20819
 
20820
20820
 
20821
20821
 
20822
+
20822
20823
  //===----------------------------------------------------------------------===//
20823
20824
  // DuckDB
20824
20825
  //
@@ -20844,6 +20845,9 @@ enum class IndexType {
20844
20845
  } // namespace duckdb
20845
20846
 
20846
20847
 
20848
+
20849
+
20850
+
20847
20851
  //===----------------------------------------------------------------------===//
20848
20852
  // DuckDB
20849
20853
  //
@@ -21115,7 +21119,7 @@ private:
21115
21119
  //===----------------------------------------------------------------------===//
21116
21120
  // DuckDB
21117
21121
  //
21118
- // duckdb/storage/table_statistics.hpp
21122
+ // duckdb/storage/statistics/column_statistics.hpp
21119
21123
  //
21120
21124
  //
21121
21125
  //===----------------------------------------------------------------------===//
@@ -21124,16 +21128,20 @@ private:
21124
21128
 
21125
21129
 
21126
21130
 
21127
-
21128
21131
  namespace duckdb {
21129
21132
 
21130
- struct TableStatistics {
21131
- idx_t estimated_cardinality;
21133
+ class ColumnStatistics {
21134
+ public:
21135
+ explicit ColumnStatistics(unique_ptr<BaseStatistics> stats_p);
21136
+
21137
+ unique_ptr<BaseStatistics> stats;
21138
+
21139
+ public:
21140
+ static shared_ptr<ColumnStatistics> CreateEmptyStats(const LogicalType &type);
21132
21141
  };
21133
21142
 
21134
21143
  } // namespace duckdb
21135
21144
 
21136
-
21137
21145
  //===----------------------------------------------------------------------===//
21138
21146
  // DuckDB
21139
21147
  //
@@ -21759,12 +21767,10 @@ private:
21759
21767
 
21760
21768
 
21761
21769
 
21762
-
21763
-
21764
21770
  //===----------------------------------------------------------------------===//
21765
21771
  // DuckDB
21766
21772
  //
21767
- // duckdb/storage/statistics/column_statistics.hpp
21773
+ // duckdb/storage/table_statistics.hpp
21768
21774
  //
21769
21775
  //
21770
21776
  //===----------------------------------------------------------------------===//
@@ -21773,24 +21779,17 @@ private:
21773
21779
 
21774
21780
 
21775
21781
 
21776
- namespace duckdb {
21777
-
21778
- class ColumnStatistics {
21779
- public:
21780
- explicit ColumnStatistics(unique_ptr<BaseStatistics> stats_p);
21781
21782
 
21782
- unique_ptr<BaseStatistics> stats;
21783
+ namespace duckdb {
21783
21784
 
21784
- public:
21785
- static shared_ptr<ColumnStatistics> CreateEmptyStats(const LogicalType &type);
21785
+ struct TableStatistics {
21786
+ idx_t estimated_cardinality;
21786
21787
  };
21787
21788
 
21788
21789
  } // namespace duckdb
21789
21790
 
21790
21791
 
21791
21792
 
21792
-
21793
-
21794
21793
  namespace duckdb {
21795
21794
  class ClientContext;
21796
21795
  class ColumnDefinition;
@@ -21981,6 +21980,7 @@ public:
21981
21980
  }
21982
21981
 
21983
21982
  unique_ptr<BaseStatistics> GetStatistics(ClientContext &context, column_t column_id);
21983
+ void SetStatistics(column_t column_id, const std::function<void(BaseStatistics &)> &set_fun);
21984
21984
 
21985
21985
  //! Checkpoint the table to the specified table data writer
21986
21986
  BlockPointer Checkpoint(TableDataWriter &writer);
@@ -25327,10 +25327,91 @@ public:
25327
25327
 
25328
25328
 
25329
25329
 
25330
+ //===----------------------------------------------------------------------===//
25331
+ // DuckDB
25332
+ //
25333
+ // duckdb/planner/tableref/bound_basetableref.hpp
25334
+ //
25335
+ //
25336
+ //===----------------------------------------------------------------------===//
25337
+
25338
+
25339
+
25340
+ //===----------------------------------------------------------------------===//
25341
+ // DuckDB
25342
+ //
25343
+ // duckdb/planner/bound_tableref.hpp
25344
+ //
25345
+ //
25346
+ //===----------------------------------------------------------------------===//
25347
+
25348
+
25349
+
25350
+
25351
+
25352
+
25353
+
25330
25354
  namespace duckdb {
25331
25355
 
25356
+ class BoundTableRef {
25357
+ public:
25358
+ explicit BoundTableRef(TableReferenceType type) : type(type) {
25359
+ }
25360
+ virtual ~BoundTableRef() {
25361
+ }
25362
+
25363
+ //! The type of table reference
25364
+ TableReferenceType type;
25365
+ //! The sample options (if any)
25366
+ unique_ptr<SampleOptions> sample;
25367
+ };
25368
+ } // namespace duckdb
25369
+
25370
+
25371
+
25372
+ namespace duckdb {
25373
+ class TableCatalogEntry;
25374
+
25375
+ //! Represents a TableReference to a base table in the schema
25376
+ class BoundBaseTableRef : public BoundTableRef {
25377
+ public:
25378
+ BoundBaseTableRef(TableCatalogEntry *table, unique_ptr<LogicalOperator> get)
25379
+ : BoundTableRef(TableReferenceType::BASE_TABLE), table(table), get(move(get)) {
25380
+ }
25381
+
25382
+ TableCatalogEntry *table;
25383
+ unique_ptr<LogicalOperator> get;
25384
+ };
25385
+ } // namespace duckdb
25386
+
25387
+
25388
+ namespace duckdb {
25389
+
25390
+ struct VacuumOptions {
25391
+ bool vacuum;
25392
+ bool analyze;
25393
+ };
25394
+
25332
25395
  struct VacuumInfo : public ParseInfo {
25333
- // nothing for now
25396
+ public:
25397
+ explicit VacuumInfo(VacuumOptions options) : options(options), has_table(false) {};
25398
+
25399
+ unique_ptr<VacuumInfo> Copy() {
25400
+ auto result = make_unique<VacuumInfo>(options);
25401
+ result->has_table = has_table;
25402
+ if (has_table) {
25403
+ result->ref = ref->Copy();
25404
+ }
25405
+ return result;
25406
+ }
25407
+
25408
+ const VacuumOptions options;
25409
+
25410
+ public:
25411
+ bool has_table;
25412
+ unique_ptr<TableRef> ref;
25413
+ unique_ptr<BoundBaseTableRef> bound_ref;
25414
+ vector<string> columns;
25334
25415
  };
25335
25416
 
25336
25417
  } // namespace duckdb