Package org.hibernate.cfg

Examples of org.hibernate.cfg.ObjectNameNormalizer.normalizeIdentifierQuoting()


        )
    );

    StringBuffer buf = new StringBuffer();
    for ( int i=0; i < tables.length; i++ ) {
      final String tableName = dialect.quote( normalizer.normalizeIdentifierQuoting( tables[i] ) );
      if ( tables.length > 1 ) {
        buf.append( "select " ).append( column ).append( " from " );
      }
      buf.append( Table.qualify( catalog, schema, tableName ) );
      if ( i < tables.length-1 ) {
View Full Code Here


   */
  protected String determineSequenceName(Properties params, Dialect dialect) {
    ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
    String sequenceName = ConfigurationHelper.getString( SEQUENCE_PARAM, params, DEF_SEQUENCE_NAME );
    if ( sequenceName.indexOf( '.' ) < 0 ) {
      sequenceName = normalizer.normalizeIdentifierQuoting( sequenceName );
      String schemaName = params.getProperty( SCHEMA );
      String catalogName = params.getProperty( CATALOG );
      sequenceName = Table.qualify(
          dialect.quote( catalogName ),
          dialect.quote( schemaName ),
View Full Code Here

   * @return The value column name
   */
  protected String determineValueColumnName(Properties params, Dialect dialect) {
    ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
    String name = ConfigurationHelper.getString( VALUE_COLUMN_PARAM, params, DEF_VALUE_COLUMN );
    return dialect.quote( normalizer.normalizeIdentifierQuoting( name ) );
  }

  /**
   * Determine the initial sequence value to use.  This value is used when
   * initializing the {@link #getDatabaseStructure() database structure}
View Full Code Here

    ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );

    tableName = ConfigurationHelper.getString( TABLE, params, DEFAULT_TABLE_NAME );
    if ( tableName.indexOf( '.' ) < 0 ) {
      final String schemaName = normalizer.normalizeIdentifierQuoting( params.getProperty( SCHEMA ) );
      final String catalogName = normalizer.normalizeIdentifierQuoting( params.getProperty( CATALOG ) );
      tableName = Table.qualify(
          dialect.quote( catalogName ),
          dialect.quote( schemaName ),
          dialect.quote( tableName )
View Full Code Here

    ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );

    tableName = ConfigurationHelper.getString( TABLE, params, DEFAULT_TABLE_NAME );
    if ( tableName.indexOf( '.' ) < 0 ) {
      final String schemaName = normalizer.normalizeIdentifierQuoting( params.getProperty( SCHEMA ) );
      final String catalogName = normalizer.normalizeIdentifierQuoting( params.getProperty( CATALOG ) );
      tableName = Table.qualify(
          dialect.quote( catalogName ),
          dialect.quote( schemaName ),
          dialect.quote( tableName )
      );
View Full Code Here

      // if already qualified there is not much we can do in a portable manner so we pass it
      // through and assume the user has set up the name correctly.
    }

    columnName = dialect.quote(
        normalizer.normalizeIdentifierQuoting(
            ConfigurationHelper.getString( COLUMN, params, DEFAULT_COLUMN_NAME )
        )
    );

    query = "select " +
View Full Code Here

  protected String determineGeneratorTableName(Properties params, Dialect dialect) {
    String name = ConfigurationHelper.getString( TABLE_PARAM, params, DEF_TABLE );
    boolean isGivenNameUnqualified = name.indexOf( '.' ) < 0;
    if ( isGivenNameUnqualified ) {
      ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
      name = normalizer.normalizeIdentifierQuoting( name );
      // if the given name is un-qualified we may neen to qualify it
      String schemaName = normalizer.normalizeIdentifierQuoting( params.getProperty( SCHEMA ) );
      String catalogName = normalizer.normalizeIdentifierQuoting( params.getProperty( CATALOG ) );
      name = Table.qualify(
          dialect.quote( catalogName ),
View Full Code Here

    boolean isGivenNameUnqualified = name.indexOf( '.' ) < 0;
    if ( isGivenNameUnqualified ) {
      ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
      name = normalizer.normalizeIdentifierQuoting( name );
      // if the given name is un-qualified we may neen to qualify it
      String schemaName = normalizer.normalizeIdentifierQuoting( params.getProperty( SCHEMA ) );
      String catalogName = normalizer.normalizeIdentifierQuoting( params.getProperty( CATALOG ) );
      name = Table.qualify(
          dialect.quote( catalogName ),
          dialect.quote( schemaName ),
          dialect.quote( name)
View Full Code Here

    if ( isGivenNameUnqualified ) {
      ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
      name = normalizer.normalizeIdentifierQuoting( name );
      // if the given name is un-qualified we may neen to qualify it
      String schemaName = normalizer.normalizeIdentifierQuoting( params.getProperty( SCHEMA ) );
      String catalogName = normalizer.normalizeIdentifierQuoting( params.getProperty( CATALOG ) );
      name = Table.qualify(
          dialect.quote( catalogName ),
          dialect.quote( schemaName ),
          dialect.quote( name)
      );
View Full Code Here

   * @return The name of the segment column
   */
  protected String determineSegmentColumnName(Properties params, Dialect dialect) {
    ObjectNameNormalizer normalizer = ( ObjectNameNormalizer ) params.get( IDENTIFIER_NORMALIZER );
    String name = ConfigurationHelper.getString( SEGMENT_COLUMN_PARAM, params, DEF_SEGMENT_COLUMN );
    return dialect.quote( normalizer.normalizeIdentifierQuoting( name ) );
  }

  /**
   * Determine the name of the column in which we will store the generator persistent value.
   * <p/>
 
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.