本文整理了Java中org.teiid.query.sql.lang.Query.setOption
方法的一些代码示例,展示了Query.setOption
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.setOption
方法的具体详情如下:
包路径:org.teiid.query.sql.lang.Query
类名称:Query
方法名:setOption
暂无
代码示例来源:origin: org.teiid/teiid-engine
/**
* Constructs an instance of this class given the specified clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: org.jboss.teiid/teiid-engine
/**
* Constructs an instance of this class given the specified clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: teiid/teiid
/**
* Constructs an instance of this class given the specified clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: org.jboss.teiid/teiid-engine
/**
* Constructs an instance of this class given all the clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param groupBy GROUP BY clause
* @param having HAVING clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, GroupBy groupBy, Criteria having, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setGroupBy( groupBy );
setHaving( having );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: teiid/teiid
/**
* Constructs an instance of this class given all the clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param groupBy GROUP BY clause
* @param having HAVING clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, GroupBy groupBy, Criteria having, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setGroupBy( groupBy );
setHaving( having );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: org.teiid/teiid-engine
/**
* Constructs an instance of this class given all the clauses
* @param select SELECT clause
* @param from FROM clause
* @param criteria WHERE clause
* @param groupBy GROUP BY clause
* @param having HAVING clause
* @param orderBy ORDER BY clause
* @param option OPTION clause
*/
public Query( Select select, From from, Criteria criteria, GroupBy groupBy, Criteria having, OrderBy orderBy, Option option ) {
super();
setSelect( select );
setFrom( from );
setCriteria( criteria );
setGroupBy( groupBy );
setHaving( having );
setOrderBy( orderBy );
setOption( option );
}
代码示例来源:origin: org.teiid/teiid-engine
ExpressionMappingVisitor.mapExpressions(select, expressionMap, true);
outerQuery.setSelect(select);
outerQuery.setOption(query.getOption());
query = outerQuery;
return query;
代码示例来源:origin: teiid/teiid
ExpressionMappingVisitor.mapExpressions(select, expressionMap, true);
outerQuery.setSelect(select);
outerQuery.setOption(query.getOption());
query = outerQuery;
return query;
代码示例来源:origin: org.jboss.teiid/teiid-engine
query.setOption(nested.getOption()!=null?(Option) nested.getOption().clone():null);
from.getClauses().clear();
SubqueryFromClause sqfc = new SubqueryFromClause(inlineGroup.getName());
代码示例来源:origin: org.teiid/teiid-engine
query.setOption(nested.getOption()!=null?(Option) nested.getOption().clone():null);
from.getClauses().clear();
SubqueryFromClause sqfc = new SubqueryFromClause(inlineGroup.getName());
代码示例来源:origin: teiid/teiid
query.setOption(nested.getOption()!=null?(Option) nested.getOption().clone():null);
from.getClauses().clear();
SubqueryFromClause sqfc = new SubqueryFromClause(inlineGroup.getName());
代码示例来源:origin: teiid/teiid
@Test public void testOptionNoCache3(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.setNoCache(true);
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option nocache", //$NON-NLS-1$
"SELECT a FROM db.g OPTION NOCACHE", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeDependent1(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addDependentGroup("a.b.c"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makedep a.b.c", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKEDEP a.b.c", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeNotDependent1(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addNotDependentGroup("a.b.c"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makenotdep a.b.c", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKENOTDEP a.b.c", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionNoCache1(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.setNoCache(true);
option.addNoCacheGroup("a.b.c"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option nocache a.b.c", //$NON-NLS-1$
"SELECT a FROM db.g OPTION NOCACHE a.b.c", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeDependent2(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addDependentGroup("a.b.c"); //$NON-NLS-1$
option.addDependentGroup("d.e.f"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makedep a.b.c, d.e.f", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKEDEP a.b.c, d.e.f", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeNotDependent2(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addNotDependentGroup("a.b.c"); //$NON-NLS-1$
option.addNotDependentGroup("d.e.f"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makeNOTdep a.b.c, d.e.f", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKENOTDEP a.b.c, d.e.f", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeNotDependent3(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addNotDependentGroup("a.b.c"); //$NON-NLS-1$
option.addNotDependentGroup("d.e.f"); //$NON-NLS-1$
option.addNotDependentGroup("x.y.z"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makenotdep a.b.c, d.e.f, x.y.z", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKENOTDEP a.b.c, d.e.f, x.y.z", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionNoCache2(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.setNoCache(true);
option.addNoCacheGroup("a.b.c"); //$NON-NLS-1$
option.addNoCacheGroup("d.e.f"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option nocache a.b.c, d.e.f", //$NON-NLS-1$
"SELECT a FROM db.g OPTION NOCACHE a.b.c, d.e.f", //$NON-NLS-1$
query);
}
代码示例来源:origin: teiid/teiid
@Test public void testOptionMakeDependent3(){
GroupSymbol g = new GroupSymbol("db.g"); //$NON-NLS-1$
From from = new From();
from.addGroup(g);
Select select = new Select();
ElementSymbol a = new ElementSymbol("a"); //$NON-NLS-1$
select.addSymbol(a);
Option option = new Option();
option.addDependentGroup("a.b.c"); //$NON-NLS-1$
option.addDependentGroup("d.e.f"); //$NON-NLS-1$
option.addDependentGroup("x.y.z"); //$NON-NLS-1$
Query query = new Query();
query.setSelect(select);
query.setFrom(from);
query.setOption(option);
TestParser.helpTest("Select a From db.g Option makedep a.b.c, d.e.f, x.y.z", //$NON-NLS-1$
"SELECT a FROM db.g OPTION MAKEDEP a.b.c, d.e.f, x.y.z", //$NON-NLS-1$
query);
}
内容来源于网络,如有侵权,请联系作者删除!