本文整理了Java中io.ebean.Query.setDistinct
方法的一些代码示例,展示了Query.setDistinct
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.setDistinct
方法的具体详情如下:
包路径:io.ebean.Query
类名称:Query
方法名:setDistinct
[英]Set whether this query uses DISTINCT.
The select() clause MUST be specified when setDistinct(true) is set. The reason for this is that generally ORM queries include the "id" property and this doesn't make sense for distinct queries.
List customers =
[中]设置此查询是否使用DISTINCT。
设置setDistinct(true)时必须指定select()子句。这样做的原因是,ORM查询通常包含“id”属性,这对于不同的查询没有意义。
List customers =
代码示例来源:origin: ebean-orm/ebean
@Override
public Query<T> setDistinct(boolean distinct) {
return query.setDistinct(distinct);
}
代码示例来源:origin: org.actframework/act-ebean
@Override
public EbeanQuery<MODEL_TYPE> setDistinct(boolean isDistinct) {
q.setDistinct(isDistinct);
qReadOnly.setDistinct(isDistinct);
return this;
}
代码示例来源:origin: org.actframework/act-ebean2
@Override
public EbeanQuery<MODEL_TYPE> setDistinct(boolean isDistinct) {
q.setDistinct(isDistinct);
return this;
}
代码示例来源:origin: io.ebean/ebean-querybean
/**
* Set whether this query uses DISTINCT.
*/
public R setDistinct(boolean distinct) {
query.setDistinct(distinct);
return root;
}
代码示例来源:origin: io.ebean/ebean
@Override
public Query<T> setDistinct(boolean distinct) {
return query.setDistinct(distinct);
}
代码示例来源:origin: icode/ameba
/**
* {@inheritDoc}
* Sets whether this query uses <code>DISTINCT</code>.
*/
public Query<T> setDistinct(boolean isDistinct) {
return query().setDistinct(isDistinct);
}
内容来源于网络,如有侵权,请联系作者删除!