duckdb 0.5.1 → 0.5.2-dev16.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 +1 -1
- package/src/duckdb.cpp +25 -9
- package/src/duckdb.hpp +2 -2
- package/src/parquet-amalgamation.cpp +37455 -37455
package/package.json
CHANGED
package/src/duckdb.cpp
CHANGED
|
@@ -43588,12 +43588,16 @@ hash_t Hash(hugeint_t val) {
|
|
|
43588
43588
|
|
|
43589
43589
|
template <>
|
|
43590
43590
|
hash_t Hash(float val) {
|
|
43591
|
-
|
|
43591
|
+
static_assert(sizeof(float) == sizeof(uint32_t), "");
|
|
43592
|
+
uint32_t uval = *((uint32_t *)&val);
|
|
43593
|
+
return murmurhash64(uval);
|
|
43592
43594
|
}
|
|
43593
43595
|
|
|
43594
43596
|
template <>
|
|
43595
43597
|
hash_t Hash(double val) {
|
|
43596
|
-
|
|
43598
|
+
static_assert(sizeof(double) == sizeof(uint64_t), "");
|
|
43599
|
+
uint64_t uval = *((uint64_t *)&val);
|
|
43600
|
+
return murmurhash64(uval);
|
|
43597
43601
|
}
|
|
43598
43602
|
|
|
43599
43603
|
template <>
|
|
@@ -120916,6 +120920,13 @@ static void PragmaStorageInfoFunction(ClientContext &context, TableFunctionInput
|
|
|
120916
120920
|
auto &bind_data = (PragmaStorageFunctionData &)*data_p.bind_data;
|
|
120917
120921
|
auto &data = (PragmaStorageOperatorData &)*data_p.global_state;
|
|
120918
120922
|
idx_t count = 0;
|
|
120923
|
+
map<storage_t, column_t> soid_to_idx;
|
|
120924
|
+
for (idx_t cidx = 0; cidx < bind_data.table_entry->columns.size(); cidx++) {
|
|
120925
|
+
auto &entry = bind_data.table_entry->columns[cidx];
|
|
120926
|
+
if (!entry.Generated()) {
|
|
120927
|
+
soid_to_idx[entry.StorageOid()] = entry.Oid();
|
|
120928
|
+
}
|
|
120929
|
+
}
|
|
120919
120930
|
while (data.offset < bind_data.storage_info.size() && count < STANDARD_VECTOR_SIZE) {
|
|
120920
120931
|
auto &entry = bind_data.storage_info[data.offset++];
|
|
120921
120932
|
D_ASSERT(entry.size() + 1 == output.ColumnCount());
|
|
@@ -120923,8 +120934,9 @@ static void PragmaStorageInfoFunction(ClientContext &context, TableFunctionInput
|
|
|
120923
120934
|
for (idx_t col_idx = 0; col_idx < entry.size(); col_idx++, result_idx++) {
|
|
120924
120935
|
if (col_idx == 1) {
|
|
120925
120936
|
// write the column name
|
|
120926
|
-
auto
|
|
120927
|
-
output.SetValue(result_idx, count,
|
|
120937
|
+
auto storage_column_index = entry[col_idx].GetValue<int64_t>();
|
|
120938
|
+
output.SetValue(result_idx, count,
|
|
120939
|
+
Value(bind_data.table_entry->columns[soid_to_idx[storage_column_index]].Name()));
|
|
120928
120940
|
result_idx++;
|
|
120929
120941
|
}
|
|
120930
120942
|
output.SetValue(result_idx, count, entry[col_idx]);
|
|
@@ -197917,8 +197929,9 @@ void DataTable::VerifyAppendConstraints(TableCatalogEntry &table, ClientContext
|
|
|
197917
197929
|
auto &constraint = table.bound_constraints[i];
|
|
197918
197930
|
switch (base_constraint->type) {
|
|
197919
197931
|
case ConstraintType::NOT_NULL: {
|
|
197920
|
-
auto &
|
|
197921
|
-
|
|
197932
|
+
auto &bound_not_null = *reinterpret_cast<BoundNotNullConstraint *>(constraint.get());
|
|
197933
|
+
auto ¬_null = *reinterpret_cast<NotNullConstraint *>(base_constraint.get());
|
|
197934
|
+
VerifyNotNullConstraint(table, chunk.data[bound_not_null.index], chunk.size(),
|
|
197922
197935
|
table.columns[not_null.index].Name());
|
|
197923
197936
|
break;
|
|
197924
197937
|
}
|
|
@@ -198389,13 +198402,16 @@ static bool CreateMockChunk(TableCatalogEntry &table, const vector<column_t> &co
|
|
|
198389
198402
|
|
|
198390
198403
|
void DataTable::VerifyUpdateConstraints(TableCatalogEntry &table, DataChunk &chunk,
|
|
198391
198404
|
const vector<column_t> &column_ids) {
|
|
198392
|
-
for (
|
|
198405
|
+
for (idx_t i = 0; i < table.bound_constraints.size(); i++) {
|
|
198406
|
+
auto &base_constraint = table.constraints[i];
|
|
198407
|
+
auto &constraint = table.bound_constraints[i];
|
|
198393
198408
|
switch (constraint->type) {
|
|
198394
198409
|
case ConstraintType::NOT_NULL: {
|
|
198395
|
-
auto &
|
|
198410
|
+
auto &bound_not_null = *reinterpret_cast<BoundNotNullConstraint *>(constraint.get());
|
|
198411
|
+
auto ¬_null = *reinterpret_cast<NotNullConstraint *>(base_constraint.get());
|
|
198396
198412
|
// check if the constraint is in the list of column_ids
|
|
198397
198413
|
for (idx_t i = 0; i < column_ids.size(); i++) {
|
|
198398
|
-
if (column_ids[i] ==
|
|
198414
|
+
if (column_ids[i] == bound_not_null.index) {
|
|
198399
198415
|
// found the column id: check the data in
|
|
198400
198416
|
VerifyNotNullConstraint(table, chunk.data[i], chunk.size(), table.columns[not_null.index].Name());
|
|
198401
198417
|
break;
|
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 "
|
|
15
|
-
#define DUCKDB_VERSION "v0.5.
|
|
14
|
+
#define DUCKDB_SOURCE_ID "d41a2e811"
|
|
15
|
+
#define DUCKDB_VERSION "v0.5.2-dev16"
|
|
16
16
|
//===----------------------------------------------------------------------===//
|
|
17
17
|
// DuckDB
|
|
18
18
|
//
|