Examples of OuterJoinLoadable


Examples of org.hibernate.persister.entity.OuterJoinLoadable

    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();
  }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

  public String toSqlString(Criteria criteria, CriteriaQuery criteriaQuery)
  throws HibernateException {

    final SessionFactoryImplementor factory = criteriaQuery.getFactory();
    final OuterJoinLoadable persister = (OuterJoinLoadable) factory.getEntityPersister( criteriaImpl.getEntityOrClassName() );

    createAndSetInnerQuery( criteriaQuery, factory );
   
    CriteriaJoinWalker walker = new CriteriaJoinWalker(
        persister,
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

    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();
  }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

                  final QueryableCollection collectionPersister = (QueryableCollection) joinable;
                  lhsTableName = collectionPersister.getTableName();
                  lhsColumnNames = collectionPersister.getElementColumnNames();
                }
                else {
                  final OuterJoinLoadable entityPersister = (OuterJoinLoadable) locateOwningPersister();
                  lhsTableName = getLHSTableName( aType, attributeNumber(), entityPersister );
                  lhsColumnNames = getLHSColumnNames(
                      aType,
                      attributeNumber(),
                      columnPosition,
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

    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();
  }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

    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();
  }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

          getCollectionReferenceAliases().getCollectionTableAlias(),
          getCollectionReferenceAliases().getCollectionColumnAliases().getSuffix()
      )
    );
    if ( getQueryableCollection().isManyToMany() ) {
      final OuterJoinLoadable elementPersister = (OuterJoinLoadable) getQueryableCollection().getElementPersister();
      selectStatementBuilder.appendSelectClauseFragment(
          elementPersister.selectFragment(
              getCollectionReferenceAliases().getElementTableAlias(),
              getCollectionReferenceAliases().getEntityElementAliases().getColumnAliases().getSuffix()
          )
      );
    }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

    if ( quantifier != null ) {
      buf.append( quantifier ).append( ' ' );
    }

    final SessionFactoryImplementor factory = criteriaQuery.getFactory();
    final OuterJoinLoadable persister =
        (OuterJoinLoadable) factory.getEntityPersister( criteriaImpl.getEntityOrClassName() );

    createAndSetInnerQuery( criteriaQuery, factory );
    criteriaImpl.setSession( deriveRootSession( criteria ) );
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

    super.applyRootReturnSelectFragments( selectStatementBuilder );
  }

  @Override
  protected void applyRootReturnTableFragments(SelectStatementBuilder selectStatementBuilder) {
    final OuterJoinLoadable elementOuterJoinLoadable =
        (OuterJoinLoadable) getElementEntityReference().getEntityPersister();
    //final String tableAlias = getCollectionReferenceAliases().getCollectionTableAlias();
    final String tableAlias = getElementEntityReferenceAliases().getTableAlias();
    final String fragment =
        elementOuterJoinLoadable.fromTableFragment( tableAlias ) +
            elementOuterJoinLoadable.fromJoinFragment( tableAlias, true, true);
    selectStatementBuilder.appendFromClauseFragment( fragment );
  }
View Full Code Here

Examples of org.hibernate.persister.entity.OuterJoinLoadable

   * @see org.hibernate.persister.entity.Joinable#fromJoinFragment(java.lang.String, boolean, boolean)
   */
  protected void applyRootReturnTableFragments(SelectStatementBuilder select) {
    final String fromTableFragment;
    final String rootAlias = entityReferenceAliases.getTableAlias();
    final OuterJoinLoadable outerJoinLoadable = (OuterJoinLoadable) getRootEntityReturn().getEntityPersister();
    if ( getQueryBuildingParameters().getLockOptions() != null ) {
      fromTableFragment = getSessionFactory().getDialect().appendLockHint(
          getQueryBuildingParameters().getLockOptions(),
          outerJoinLoadable.fromTableFragment( rootAlias )
      );
      select.setLockOptions( getQueryBuildingParameters().getLockOptions() );
    }
    else if ( getQueryBuildingParameters().getLockMode() != null ) {
      fromTableFragment = getSessionFactory().getDialect().appendLockHint(
          getQueryBuildingParameters().getLockMode(),
          outerJoinLoadable.fromTableFragment( rootAlias )
      );
      select.setLockMode( getQueryBuildingParameters().getLockMode() );
    }
    else {
      fromTableFragment = outerJoinLoadable.fromTableFragment( rootAlias );
    }
    select.appendFromClauseFragment( fromTableFragment + outerJoinLoadable.fromJoinFragment( rootAlias, true, true ) );
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.