Java JDBC Database Metadata isOracleForSid(DatabaseMetaData metadata, String oracleProduct)

Here you can find the source of isOracleForSid(DatabaseMetaData metadata, String oracleProduct)

Description

is Oracle For Sid

License

Open Source License

Declaration

public static boolean isOracleForSid(DatabaseMetaData metadata, String oracleProduct) throws SQLException 

Method Source Code

//package com.java2s;
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt

import java.sql.DatabaseMetaData;

import java.sql.SQLException;

public class Main {
    public static boolean isOracleForSid(DatabaseMetaData metadata, String oracleProduct) throws SQLException {
        if (metadata != null && metadata.getDatabaseProductName() != null
                && metadata.getDatabaseProductName().indexOf(oracleProduct) > -1) {
            return true;
        }//from w w  w  .  j a  v  a 2 s.  c om
        return false;
    }
}

Related

  1. isDB2(DatabaseMetaData metadata)
  2. isDerbyDatabase(DatabaseMetaData metaData)
  3. isExistsTable(Connection con, String schema, String tableName)
  4. isIdGenerated(DatabaseMetaData metaData)
  5. isMysql(DatabaseMetaData metadata)
  6. isSybase(DatabaseMetaData metadata)
  7. isSybaseDb(DatabaseMetaData metaData)
  8. printExistingTables(Connection conn)
  9. printMetaData(Connection con)