Skip to content

Commit

Permalink
Format fix
Browse files Browse the repository at this point in the history
Adding alter table test
  • Loading branch information
Dtenwolde committed Jul 4, 2023
1 parent 7d68352 commit 07f0f0c
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 18 deletions.
2 changes: 1 addition & 1 deletion src/include/duckdb/common/compressed_sparse_row.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ class CSR {
bool initialized_e = false;
bool initialized_w = false;

size_t vsize;
size_t vsize;
};
} // namespace duckdb
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ struct CreatePropertyGraphInfo : public CreateInfo {
public:
// string ToString() const;
// bool Equals(const BaseExpression *other_p) const;
// void SerializeInternal(Serializer &serializer) const override;
// void SerializeInternal(Serializer &serializer) const override;
unique_ptr<CreateInfo> Copy() const override;

//! Serializes a blob into a CreatePropertyGraphInfo
void SerializeInternal(Serializer &serializer) const override;
void SerializeInternal(Serializer &serializer) const override;
//! Deserializes a blob back into a CreatePropertyGraphInfo
static unique_ptr<CreateInfo> Deserialize(FieldReader &reader);
};
Expand Down
14 changes: 7 additions & 7 deletions src/parser/parser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -193,8 +193,8 @@ void Parser::ParseQuery(const string &query) {
auto query_statements = SplitQueryStringIntoStatements(query);
for (auto const &query_statement : query_statements) {
bool parse_success = false;
string another_parser_error;
int another_parser_error_location;
string another_parser_error;
int another_parser_error_location;
{
PostgresParser another_parser;
another_parser.Parse(query_statement);
Expand All @@ -208,9 +208,9 @@ void Parser::ParseQuery(const string &query) {
}
transformer.TransformParseTree(another_parser.parse_tree, statements);
} else {
another_parser_error = another_parser.error_message;
another_parser_error_location = another_parser.error_location;
}
another_parser_error = another_parser.error_message;
another_parser_error_location = another_parser.error_location;
}
}
if (!parse_success) {
// let extensions parse the statement which DuckDB failed to parse
Expand All @@ -233,8 +233,8 @@ void Parser::ParseQuery(const string &query) {
}
}
if (!parsed_single_statement) {
parser_error = QueryErrorContext::Format(query,
another_parser_error,another_parser_error_location - 1);
parser_error =
QueryErrorContext::Format(query, another_parser_error, another_parser_error_location - 1);
throw ParserException(parser_error);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@ Transformer::TransformPropertyGraphTable(duckdb_libpgquery::PGPropertyGraphTable
all_columns = true;
continue;
}
// auto column_alias __attribute__((unused)) =
// reinterpret_cast<duckdb_libpgquery::PGColumnDef *>(column_optional_as->head->next->data.ptr_value);
// auto column_alias __attribute__((unused)) =
// reinterpret_cast<duckdb_libpgquery::PGColumnDef
//*>(column_optional_as->head->next->data.ptr_value);
// TODO
// - Change this to support the optional as
// Looking at the next element of column_optional_as, which is a linked list
Expand Down
10 changes: 5 additions & 5 deletions src/planner/logical_operator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -344,11 +344,11 @@ unique_ptr<LogicalOperator> LogicalOperator::Deserialize(Deserializer &deseriali
case LogicalOperatorType::LOGICAL_TRANSACTION:
case LogicalOperatorType::LOGICAL_DROP:
case LogicalOperatorType::LOGICAL_DETACH:
result = LogicalSimple::Deserialize(state, reader);
break;
case LogicalOperatorType::LOGICAL_EXTENSION_OPERATOR:
result = LogicalExtensionOperator::Deserialize(state, reader);
break;
result = LogicalSimple::Deserialize(state, reader);
break;
case LogicalOperatorType::LOGICAL_EXTENSION_OPERATOR:
result = LogicalExtensionOperator::Deserialize(state, reader);
break;
case LogicalOperatorType::LOGICAL_PIVOT:
result = LogicalPivot::Deserialize(state, reader);
break;
Expand Down
2 changes: 1 addition & 1 deletion src/planner/planner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ void Planner::CreatePlan(SQLStatement &statement) {
throw;
}
} catch (std::exception &ex) {
throw;
throw;
}
this->properties = binder->properties;
this->properties.parameter_count = parameter_count;
Expand Down

0 comments on commit 07f0f0c

Please sign in to comment.