Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix union tag bug #1936

Merged
merged 1 commit into from
Aug 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/common/vector/value_vector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ ValueVector::ValueVector(LogicalType dataType, storage::MemoryManager* memoryMan

void ValueVector::setState(std::shared_ptr<DataChunkState> state) {
this->state = state;
if (dataType.getLogicalTypeID() == LogicalTypeID::STRUCT) {
if (dataType.getPhysicalType() == PhysicalTypeID::STRUCT) {
auto childrenVectors = StructVector::getFieldVectors(this);
for (auto& childVector : childrenVectors) {
childVector->setState(state);
Expand Down
7 changes: 7 additions & 0 deletions test/test_files/tinysnb/projection/single_label.test
Original file line number Diff line number Diff line change
Expand Up @@ -663,6 +663,13 @@ NO hex code
---- 1
hEl '"\

-LOG ReturnUnionTag
-STATEMENT MATCH (m:movies) RETURN union_tag(m.grade)
---- 3
credit
grade1
grade1

-CASE LargeListOfStruct
-DEFINE STRUCT_VAL REPEAT 2400 "{a: ${count}},"
-STATEMENT RETURN list_append([${STRUCT_VAL}{a: 99}], {a: 200})
Expand Down
Loading