Package java.sql

Examples of java.sql.DatabaseMetaData.supportsTransactions()


    this.conn = conn;
    this.coding = coding;
    DatabaseMetaData dm = null;
    try{
      dm = conn.getMetaData();
      supportTransaction = dm.supportsTransactions();
      infs = conn.getClass().getInterfaces();
      if(infs==null || infs.length==0)
         infs = IC;
    }catch(Exception e){}
  }
View Full Code Here


               log.info("The maximum SQL statement length is not defined in JDBC meta data, we set it to " + this.maxStatementLength);
               first = false;
            }
         }

         if (!dbmd.supportsTransactions()) {
            String dbName = dbmd.getDatabaseProductName();
            log.severe("the database '" + dbName + "' does not support transactions, unpredicted results may happen");
         }

         if (!dbmd.supportsBatchUpdates()) {
View Full Code Here

         log.info("max connections      : " + metaData.getMaxConnections());
         log.info("max statement length : " + metaData.getMaxStatementLength());
         log.info("max nr. of statements: " + metaData.getMaxStatements());
         log.info("max tablename length : " + metaData.getMaxTableNameLength());
         log.info("url                  : " + metaData.getURL());
         log.info("support for trans.   : " + metaData.supportsTransactions());
         log.info("support transactions : " + getIsolationLevel(conn));
         log.info("--------------- DUMP OF METADATA FOR THE DB END  ---------------------");

      }
      catch (XmlBlasterException ex) {
View Full Code Here

               log.info("The maximum SQL statement length is not defined in JDBC meta data, we set it to " + this.maxStatementLength);
               first = false;
            }
         }

         if (!dbmd.supportsTransactions()) {
            String dbName = dbmd.getDatabaseProductName();
            log.severe("the database '" + dbName + "' does not support transactions, unpredicted results may happen");
         }

         if (!dbmd.supportsBatchUpdates()) {
View Full Code Here

         log.info("max connections      : " + metaData.getMaxConnections());
         log.info("max statement length : " + metaData.getMaxStatementLength());
         log.info("max nr. of statements: " + metaData.getMaxStatements());
         log.info("max tablename length : " + metaData.getMaxTableNameLength());
         log.info("url                  : " + metaData.getURL());
         log.info("support for trans.   : " + metaData.supportsTransactions());
         log.info("support transactions : " + getIsolationLevel(conn));
         log.info("--------------- DUMP OF METADATA FOR THE DB END  ---------------------");
         success = true;
      }
      catch (Exception ex) {
View Full Code Here

        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_REPEATABLE_READ));
        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_SERIALIZABLE));
       
        assertTrue(dmd.supportsTransactions());
        assertTrue(dmd.supportsUnion());
        assertTrue(dmd.supportsUnionAll());        
    }
   
    /**
 
View Full Code Here

        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_REPEATABLE_READ));
        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_SERIALIZABLE));
       
        assertTrue(dmd.supportsTransactions());
        assertTrue(dmd.supportsUnion());
        assertTrue(dmd.supportsUnionAll());        
    }
   
    /**
 
View Full Code Here

    boolean supportsOrderByUnrelated = dbMetaData.supportsOrderByUnrelated();
    boolean supportsPositionedDelete = dbMetaData.supportsPositionedDelete();

    boolean supportsSelectForUpdate = dbMetaData.supportsSelectForUpdate();
    boolean supportsStoredProcedures = dbMetaData.supportsStoredProcedures();
    boolean supportsTransactions = dbMetaData.supportsTransactions();
    boolean supportsUnion = dbMetaData.supportsUnion();
    boolean supportsUnionAll = dbMetaData.supportsUnionAll();

    int getMaxColumnNameLength = dbMetaData.getMaxColumnNameLength();
    int getMaxColumnsInIndex = dbMetaData.getMaxColumnsInIndex();
View Full Code Here

     * @throws SQLException if an SQL exception occurs.
     */
    private static void setMetaData(Connection con) throws SQLException {
        DatabaseMetaData metaData = con.getMetaData();
        // Supports transactions?
        transactionsSupported = metaData.supportsTransactions();
        // Supports subqueries?
        subqueriesSupported = metaData.supportsCorrelatedSubqueries();
        // Supports scroll insensitive result sets? Try/catch block is a
        // workaround for DB2 JDBC driver, which throws an exception on
        // the method call.
View Full Code Here

        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_REPEATABLE_READ));
        assertTrue(dmd.supportsTransactionIsolationLevel(
                Connection.TRANSACTION_SERIALIZABLE));
       
        assertTrue(dmd.supportsTransactions());
        assertTrue(dmd.supportsUnion());
        assertTrue(dmd.supportsUnionAll());        
    }
   
    /**
 
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.