Parse the (optional) schema and a name from a string in the format of e.g. "schema"."table"; if there is no dot the schema will be set to INVALID_SCHEMA
347714 {
347715 string catalog;
347716 string schema;
347717 string name;
347718
347720 if (entries.empty()) {
347721 catalog = INVALID_CATALOG;
347722 schema = INVALID_SCHEMA;
347723 } else if (entries.size() == 1) {
347724 catalog = INVALID_CATALOG;
347725 schema = INVALID_SCHEMA;
347726 name = entries[0];
347727 } else if (entries.size() == 2) {
347728 catalog = INVALID_CATALOG;
347729 schema = entries[0];
347730 name = entries[1];
347731 } else if (entries.size() == 3) {
347732 catalog = entries[0];
347733 schema = entries[1];
347734 name = entries[2];
347735 } else {
347736 throw ParserException("Expected catalog.entry, schema.entry or entry: too many entries found (input: %s)",
347737 input);
347738 }
347739 return QualifiedName {catalog, schema, name};
347740}
static vector< string > ParseComponents(const string &input)
Definition duckdb.cpp:347674