private MetadataResult obtainMetadataForPreparedSql(String sql, DQPWorkContext workContext, boolean isDoubleQuotedVariablesAllowed) throws QueryParserException, QueryResolverException, TeiidComponentException { Command command = null; ParseInfo info = new ParseInfo(); // Defect 19747 - the parser needs the following connection property to decide whether to treat double-quoted strings as variable names info.ansiQuotedIdentifiers = isDoubleQuotedVariablesAllowed; CacheID id = new CacheID(workContext, info, sql); PreparedPlan plan = planCache.get(id); if(plan != null) { command = plan.getCommand(); } else { command = QueryParser.getQueryParser().parseCommand(sql, info); QueryResolver.resolveCommand(command, this.metadata); } return getMetadataForCommand(command); }
private MetadataResult obtainMetadataForPreparedSql(String sql, DQPWorkContext workContext, boolean isDoubleQuotedVariablesAllowed) throws QueryParserException, QueryResolverException, TeiidComponentException { Command command = null; ParseInfo info = new ParseInfo(); // Defect 19747 - the parser needs the following connection property to decide whether to treat double-quoted strings as variable names info.ansiQuotedIdentifiers = isDoubleQuotedVariablesAllowed; CacheID id = new CacheID(workContext, info, sql); PreparedPlan plan = planCache.get(id); if(plan != null) { command = plan.getCommand(); } else { command = QueryParser.getQueryParser().parseCommand(sql, info); QueryResolver.resolveCommand(command, this.metadata); } return getMetadataForCommand(command); }
private MetadataResult obtainMetadataForPreparedSql(String sql, DQPWorkContext workContext, boolean isDoubleQuotedVariablesAllowed) throws QueryParserException, QueryResolverException, TeiidComponentException { Command command = null; ParseInfo info = new ParseInfo(); // Defect 19747 - the parser needs the following connection property to decide whether to treat double-quoted strings as variable names info.ansiQuotedIdentifiers = isDoubleQuotedVariablesAllowed; CacheID id = new CacheID(workContext, info, sql); PreparedPlan plan = planCache.get(id); if(plan != null) { command = plan.getCommand(); } else { command = QueryParser.getQueryParser().parseCommand(sql, info); QueryResolver.resolveCommand(command, this.metadata); } return getMetadataForCommand(command); }
return getMetadataForCommand(workItem.getOriginalCommand());
return getMetadataForCommand(workItem.getOriginalCommand());
return getMetadataForCommand(workItem.getOriginalCommand());