public List<List<String>> getSchemaPaths() { return catalogReader.getSchemaPaths(); }
public List<List<String>> getSchemaPaths() { return catalogReader.getSchemaPaths(); }
public static void getSchemaObjectMonikers( SqlValidatorCatalogReader catalogReader, List<String> names, List<SqlMoniker> hints) { // Assume that the last name is 'dummy' or similar. List<String> subNames = Util.skipLast(names); // Try successively with catalog.schema, catalog and no prefix for (List<String> x : catalogReader.getSchemaPaths()) { final List<String> names2 = ImmutableList.<String>builder().addAll(x).addAll(subNames).build(); hints.addAll(catalogReader.getAllSchemaObjectNames(names2)); } }
public static void getSchemaObjectMonikers( SqlValidatorCatalogReader catalogReader, List<String> names, List<SqlMoniker> hints) { // Assume that the last name is 'dummy' or similar. List<String> subNames = Util.skipLast(names); // Try successively with catalog.schema, catalog and no prefix for (List<String> x : catalogReader.getSchemaPaths()) { final List<String> names2 = ImmutableList.<String>builder().addAll(x).addAll(subNames).build(); hints.addAll(catalogReader.getAllSchemaObjectNames(names2)); } }
public void resolveTable(List<String> names, SqlNameMatcher nameMatcher, Path path, Resolved resolved) { final List<Resolve> imperfectResolves = new ArrayList<>(); final List<Resolve> resolves = ((ResolvedImpl) resolved).resolves; // Look in the default schema, then default catalog, then root schema. for (List<String> schemaPath : validator.catalogReader.getSchemaPaths()) { resolve_(validator.catalogReader.getRootSchema(), names, schemaPath, nameMatcher, path, resolved); for (Resolve resolve : resolves) { if (resolve.remainingNames.isEmpty()) { // There is a full match. Return it as the only match. ((ResolvedImpl) resolved).clear(); resolves.add(resolve); return; } } imperfectResolves.addAll(resolves); } // If there were no matches in the last round, restore those found in // previous rounds if (resolves.isEmpty()) { resolves.addAll(imperfectResolves); } }
public void resolveTable(List<String> names, SqlNameMatcher nameMatcher, Path path, Resolved resolved) { final List<Resolve> imperfectResolves = new ArrayList<>(); final List<Resolve> resolves = ((ResolvedImpl) resolved).resolves; // Look in the default schema, then default catalog, then root schema. for (List<String> schemaPath : validator.catalogReader.getSchemaPaths()) { resolve_(validator.catalogReader.getRootSchema(), names, schemaPath, nameMatcher, path, resolved); for (Resolve resolve : resolves) { if (resolve.remainingNames.isEmpty()) { // There is a full match. Return it as the only match. ((ResolvedImpl) resolved).clear(); resolves.add(resolve); return; } } imperfectResolves.addAll(resolves); } // If there were no matches in the last round, restore those found in // previous rounds if (resolves.isEmpty()) { resolves.addAll(imperfectResolves); } }
for (List<String> schemaPath : catalogReader.getSchemaPaths()) { CalciteSchema schema = getSchema(catalogReader.getRootSchema(),
for (List<String> schemaPath : catalogReader.getSchemaPaths()) { CalciteSchema schema = getSchema(catalogReader.getRootSchema(),