Examples of QueryParameters


Examples of org.hibernate.engine.QueryParameters

  public Iterator iterate() throws HibernateException {
    throw new UnsupportedOperationException("SQL queries do not currently support iteration");
  }

  public QueryParameters getQueryParameters(Map namedParams) {
    QueryParameters qp = super.getQueryParameters(namedParams);
    qp.setCallable(callable);
    qp.setAutoDiscoverScalarTypes(autodiscovertypes);
    return qp;
  }
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

  }
 
  public ScrollableResults scroll(SessionImplementor session, ScrollMode scrollMode)
  throws HibernateException {
    QueryParameters qp = translator.getQueryParameters();
    qp.setScrollMode(scrollMode);
    return scroll(qp, resultTypes, null, session);
  }
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

    errorIfDML();
    QueryNode query = ( QueryNode ) sqlAst;
    boolean hasLimit = queryParameters.getRowSelection() != null && queryParameters.getRowSelection().definesLimits();
    boolean needsDistincting = ( query.getSelectClause().isDistinct() || hasLimit ) && containsCollectionFetches();

    QueryParameters queryParametersToUse;
    if ( hasLimit && containsCollectionFetches() ) {
      log.warn( "firstResult/maxResults specified with collection fetch; applying in memory!" );
      RowSelection selection = new RowSelection();
      selection.setFetchSize( queryParameters.getRowSelection().getFetchSize() );
      selection.setTimeout( queryParameters.getRowSelection().getTimeout() );
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

      if ( lm != null ) {
        lockModes.put( getSQLAlias( subcriteria ), lm );
      }
    }

    return new QueryParameters(
        typeArray,
            valueArray,
            lockModes,
            selection,
            rootCriteria.getCacheable(),
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

    List result;
    try {
      result = doQueryAndInitializeNonLazyCollections(
          session,
          new QueryParameters(
              new Type[] { identifierType },
              new Object[] { id },
              optionalObject,
              optionalEntityName,
              optionalIdentifier
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

    List result;
    try {
      result = doQueryAndInitializeNonLazyCollections(
          session,
          new QueryParameters(
              new Type[] { keyType, indexType },
              new Object[] { key, index }
            ),
          false
        );
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

    Arrays.fill( types, idType );
    List result;
    try {
      result = doQueryAndInitializeNonLazyCollections(
          session,
          new QueryParameters( types, ids, optionalObject, optionalEntityName, optionalId ),
          false
        );
    }
    catch ( SQLException sqle ) {
      throw JDBCExceptionHelper.convert(
View Full Code Here

Examples of org.hibernate.engine.QueryParameters

    Serializable[] ids = new Serializable[]{id};
    try {
      doQueryAndInitializeNonLazyCollections(
          session,
          new QueryParameters( new Type[]{type}, ids, ids ),
          true
        );
    }
    catch ( SQLException sqle ) {
      throw JDBCExceptionHelper.convert(
View Full Code Here

Examples of org.hibernate.engine.spi.QueryParameters

          MessageHelper.collectionInfoString( getCollectionPersisters()[0], id, getFactory() )
        );
    }

    Serializable[] ids = new Serializable[]{id};
    QueryParameters qp = new QueryParameters( new Type[]{type}, ids, ids );
    doQueryAndInitializeNonLazyCollections(
        session,
        qp,
        OgmLoadingContext.EMPTY_CONTEXT,
        true
View Full Code Here

Examples of org.hibernate.engine.spi.QueryParameters

    before();

    Map<?, ?> namedParams = getNamedParams();
    NativeNoSqlQuerySpecification spec = generateQuerySpecification( namedParams );

    QueryParameters qp = getQueryParameters( namedParams );
    qp.setScrollMode( scrollMode );

    try {
      return session.scroll( spec, qp );
    }
    finally {
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.