nl.gx.webmanager.handler.util
Class DatabaseType

java.lang.Object
  extended by nl.gx.webmanager.handler.util.DatabaseType

public class DatabaseType
extends java.lang.Object

Utility class to determine what database we are dealing with.


Field Summary
static int ACCESS
          Ms Access database.
static int DB2
          IBM DB2 database.
static int INFORMIX_DS
          Informix database on Dynamic Server (with text fields).
static int INFORMIX_SE
          Informix database on SE server (without text fields).
static int MSSQL
          MS-Sql database.
static int MYSQL
          MySQL database.
static int ORACLE
          Oracle database.
static int SOLID
          Solid database.
static int SYBASE
          Sybase database.
 
Method Summary
static int getDatabaseTypeId(java.sql.Connection c)
           
static int getDatabaseTypeId(java.lang.String productName)
          Calculates the internal database type representation accoording to the passed productName.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SOLID

public static final int SOLID
Solid database.

See Also:
Constant Field Values

INFORMIX_SE

public static final int INFORMIX_SE
Informix database on SE server (without text fields).

See Also:
Constant Field Values

INFORMIX_DS

public static final int INFORMIX_DS
Informix database on Dynamic Server (with text fields).

See Also:
Constant Field Values

ORACLE

public static final int ORACLE
Oracle database.

See Also:
Constant Field Values

ACCESS

public static final int ACCESS
Ms Access database.

See Also:
Constant Field Values

SYBASE

public static final int SYBASE
Sybase database.

See Also:
Constant Field Values

DB2

public static final int DB2
IBM DB2 database. Note untested

See Also:
Constant Field Values

MSSQL

public static final int MSSQL
MS-Sql database.

See Also:
Constant Field Values

MYSQL

public static final int MYSQL
MySQL database.

See Also:
Constant Field Values
Method Detail

getDatabaseTypeId

public static int getDatabaseTypeId(java.lang.String productName)
Calculates the internal database type representation accoording to the passed productName.

Parameters:
productName - String containing the database metadata productname.
Returns:
the internal database type
Since:
1.0

getDatabaseTypeId

public static int getDatabaseTypeId(java.sql.Connection c)
                             throws java.sql.SQLException
Throws:
java.sql.SQLException


Copyright © 2007-2010 GX creative online development BV. All Rights Reserved.