public String selectFragment( Joinable rhs, String rhsAlias, String lhsAlias, String entitySuffix, String collectionSuffix, boolean includeCollectionColumns) { StringBuilder buf = new StringBuilder(); if ( includeCollectionColumns ) { // buf.append( selectFragment( lhsAlias, "" ) )//ignore suffix for collection columns! buf.append( selectFragment( lhsAlias, collectionSuffix ) ) .append( ", " ); } OuterJoinLoadable ojl = (OuterJoinLoadable) getElementPersister(); return buf.append( ojl.selectFragment( lhsAlias, entitySuffix ) )//use suffix for the entity columns .toString(); }
protected void applyRootReturnSelectFragments(SelectStatementBuilder selectStatementBuilder) { final OuterJoinLoadable outerJoinLoadable = (OuterJoinLoadable) getRootEntityReturn().getEntityPersister(); selectStatementBuilder.appendSelectClauseFragment( outerJoinLoadable.selectFragment( entityReferenceAliases.getTableAlias(), entityReferenceAliases.getColumnAliases().getSuffix() ) ); }
@Override protected void applyRootReturnSelectFragments(SelectStatementBuilder selectStatementBuilder) { if ( getRootCollectionReturn().allowIndexJoin() && getQueryableCollection().getIndexType().isEntityType() ) { final EntityReference indexEntityReference = getRootCollectionReturn().getIndexGraph().resolveEntityReference(); final EntityReferenceAliases indexEntityReferenceAliases = getAliasResolutionContext().resolveEntityReferenceAliases( indexEntityReference.getQuerySpaceUid() ); selectStatementBuilder.appendSelectClauseFragment( ( (OuterJoinLoadable) indexEntityReference.getEntityPersister() ).selectFragment( indexEntityReferenceAliases.getTableAlias(), indexEntityReferenceAliases.getColumnAliases().getSuffix() ) ); } }
@Override protected void applyRootReturnSelectFragments(SelectStatementBuilder selectStatementBuilder) { selectStatementBuilder.appendSelectClauseFragment( getQueryableCollection().selectFragment( getCollectionReferenceAliases().getCollectionTableAlias(), getCollectionReferenceAliases().getCollectionColumnAliases().getSuffix() ) ); if ( getQueryableCollection().isManyToMany() ) { final OuterJoinLoadable elementPersister = (OuterJoinLoadable) getQueryableCollection().getElementPersister(); selectStatementBuilder.appendSelectClauseFragment( elementPersister.selectFragment( getCollectionReferenceAliases().getElementTableAlias(), getCollectionReferenceAliases().getEntityElementAliases().getColumnAliases().getSuffix() ) ); } super.applyRootReturnSelectFragments( selectStatementBuilder ); }
.setSelectClause( projection == null ? persister.selectFragment( alias, suffixes[joins] ) + selectString( associations ) : projection
elementPersister.selectFragment( elementTableAlias, aliases.getEntityElementAliases().getColumnAliases().getSuffix() elementPersister.selectFragment( aliases.getElementTableAlias(), aliases.getEntityElementAliases().getColumnAliases().getSuffix()
public String selectFragment( Joinable rhs, String rhsAlias, String lhsAlias, String entitySuffix, String collectionSuffix, boolean includeCollectionColumns) { StringBuffer buf = new StringBuffer(); if ( includeCollectionColumns ) { // buf.append( selectFragment( lhsAlias, "" ) )//ignore suffix for collection columns! buf.append( selectFragment( lhsAlias, collectionSuffix ) ) .append( ", " ); } OuterJoinLoadable ojl = ( OuterJoinLoadable ) getElementPersister(); return buf.append( ojl.selectFragment( lhsAlias, entitySuffix ) )//use suffix for the entity columns .toString(); }
public String selectFragment( Joinable rhs, String rhsAlias, String lhsAlias, String entitySuffix, String collectionSuffix, boolean includeCollectionColumns) { StringBuffer buf = new StringBuffer(); if ( includeCollectionColumns ) { // buf.append( selectFragment( lhsAlias, "" ) )//ignore suffix for collection columns! buf.append( selectFragment( lhsAlias, collectionSuffix ) ) .append( ", " ); } OuterJoinLoadable ojl = ( OuterJoinLoadable ) getElementPersister(); return buf.append( ojl.selectFragment( lhsAlias, entitySuffix ) )//use suffix for the entity columns .toString(); }
public String selectFragment( Joinable rhs, String rhsAlias, String lhsAlias, String entitySuffix, String collectionSuffix, boolean includeCollectionColumns) { StringBuffer buf = new StringBuffer(); if ( includeCollectionColumns ) { // buf.append( selectFragment( lhsAlias, "" ) )//ignore suffix for collection columns! buf.append( selectFragment( lhsAlias, collectionSuffix ) ) .append( ", " ); } OuterJoinLoadable ojl = ( OuterJoinLoadable ) getElementPersister(); return buf.append( ojl.selectFragment( lhsAlias, entitySuffix ) )//use suffix for the entity columns .toString(); }
.setSelectClause( projection==null ? persister.selectFragment( alias, suffixes[joins] ) + selectString(associations) : projection
.setSelectClause( projection == null ? persister.selectFragment( alias, suffixes[joins] ) + selectString( associations ) : projection
.setSelectClause( projection==null ? persister.selectFragment( alias, suffixes[joins] ) + selectString(associations) : projection
.setSelectClause( projection == null ? persister.selectFragment( alias, suffixes[joins] ) + selectString( associations ) : projection