usql update
This commit is contained in:
@@ -132,6 +132,7 @@ struct FunctionNode : Node {
|
||||
pp,
|
||||
lower,
|
||||
upper,
|
||||
coalesce,
|
||||
min,
|
||||
max,
|
||||
count
|
||||
@@ -144,6 +145,7 @@ struct FunctionNode : Node {
|
||||
if (str=="pp") return Type::pp;
|
||||
if (str=="lower") return Type::lower;
|
||||
if (str=="upper") return Type::upper;
|
||||
if (str=="coalesce") return Type::coalesce;
|
||||
if (str=="min") return Type::min;
|
||||
if (str=="max") return Type::max;
|
||||
if (str=="count") return Type::count;
|
||||
@@ -158,15 +160,16 @@ struct FunctionNode : Node {
|
||||
if (type == Type::pp) return "pp";
|
||||
if (type == Type::lower) return "lower";
|
||||
if (type == Type::upper) return "upper";
|
||||
if (type == Type::coalesce) return "coalesce";
|
||||
if (type == Type::min) return "min";
|
||||
if (type == Type::max) return "max";
|
||||
if (type == Type::count) return "count";
|
||||
|
||||
throw Exception("invalid function: " + (int)type);
|
||||
throw Exception("invalid function: " + std::to_string((int)type));
|
||||
};
|
||||
|
||||
|
||||
Type function;
|
||||
Type function;
|
||||
std::vector<std::unique_ptr<Node>> params;
|
||||
|
||||
FunctionNode(std::string func_name, std::vector<std::unique_ptr<Node>> pars) :
|
||||
|
||||
Reference in New Issue
Block a user