Package net.sourceforge.squirrel_sql.fw.sql

Examples of net.sourceforge.squirrel_sql.fw.sql.SQLDatabaseMetaData


         }

         st.nextToken(); // remove the function name

         String catalog = _session.getSQLConnection().getCatalog();
         SQLDatabaseMetaData jdbcMetaData = _session.getSQLConnection().getSQLMetaData();
         Vector<String> tables = new Vector<String>();
         HashMap<String, String> schemas = new HashMap<String, String>();
         while(st.hasMoreTokens())
         {
            String[] catSchemTab = st.nextToken().trim().split("\\.");
View Full Code Here


        throws SQLException
  {
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final ISQLConnection conn = session.getSQLConnection();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final String catalogName = parentDbinfo.getCatalogName();
    final String schemaName = parentDbinfo.getSchemaName();
    final ObjFilterMatcher filterMatcher = new ObjFilterMatcher(session.getProperties());

    PreparedStatement pstmt = null;
View Full Code Here

    if (conn == null)
    {
      throw new IllegalArgumentException("SQLConnection == null");
    }

    SQLDatabaseMetaData md = conn.getSQLMetaData();
    try
    {
      _targetDBMS = md.getDatabaseProductName();
    }
    catch (Throwable ignore)
    {
      _targetDBMS = UNSUPPORTED;
    }
    try
    {
      // Current version of the validator webservice cannot handle
      // anything greater than 30.
      _targetDBMSVersion = md.getDatabaseProductVersion();
      if (_targetDBMSVersion.length() > 30)
      {
        _targetDBMSVersion = _targetDBMSVersion.substring(0, 30);
      }
    }
    catch (Throwable ignore)
    {
      _targetDBMSVersion = UNSUPPORTED;
    }
    _connTechnology = "JDBC";
    try
    {
      _connTechnologyVersion = String.valueOf(md.getJDBCVersion());
    }
    catch (Throwable ignore)
    {
      _connTechnologyVersion = UNSUPPORTED;
    }
View Full Code Here

  public List<ObjectTreeNode> createChildren(ISession session, ObjectTreeNode parentNode)
    throws SQLException
  {
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final ISQLConnection conn = session.getSQLConnection();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final String schemaName = parentDbinfo.getSchemaName();

    PreparedStatement pstmt = null;
    ResultSet rs = null;
View Full Code Here

   */
  public List<ObjectTreeNode> createChildren(ISession session, ObjectTreeNode parentNode)
  {
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final String catalogName = parentDbinfo.getCatalogName();
    final String schemaName = parentDbinfo.getSimpleName();

    IDatabaseObjectInfo dbinfo = new DatabaseObjectInfo(catalogName,
                      schemaName, "PACKAGE",
View Full Code Here

    Vector<String> dataTypes = new Vector<String>();
    try
    {
      final ISQLConnection conn = _session.getSQLConnection();
      SQLDatabaseMetaData dmd = conn.getSQLMetaData();
      DataTypeInfo[] infos = dmd.getDataTypes();
            for (int i = 0; i < infos.length; i++) {
                dataTypes.add(infos[i].getSimpleName());
            }
    }
    catch (SQLException ex)
View Full Code Here

    String primaryKey = "";
    try
    {
      ISQLConnection con = _session.getSQLConnection();
      SQLDatabaseMetaData db = con.getSQLMetaData();
            PrimaryKeyInfo[] infos = db.getPrimaryKey(getTableInfo());
            for (int i=0; i < infos.length; i++) {
                primaryKey = infos[i].getColumnName();
            }
    }
    catch (SQLException ex)
View Full Code Here

    throws SQLException
  {
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final ISQLConnection conn = session.getSQLConnection();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final IDatabaseObjectInfo tableInfo = ((TriggerParentInfo)parentDbinfo).getTableInfo();
    final PreparedStatement pstmt = conn.prepareStatement(SQL);
    try
    {
      pstmt.setString(1, tableInfo.getSchemaName());
View Full Code Here

    throws SQLException
  {
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final ISQLConnection conn = session.getSQLConnection();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final String catalogName = parentDbinfo.getCatalogName();
    final String schemaName = parentDbinfo.getSchemaName();
      ObjFilterMatcher filterMatcher = new ObjFilterMatcher(session.getProperties());

View Full Code Here

    throws SQLException {
   
    final List<ObjectTreeNode> childNodes = new ArrayList<ObjectTreeNode>();
    final IDatabaseObjectInfo parentDbinfo = parentNode.getDatabaseObjectInfo();
    final ISQLConnection conn = session.getSQLConnection();
    final SQLDatabaseMetaData md = session.getSQLConnection().getSQLMetaData();
    final IDatabaseObjectInfo tableInfo = ((ConstraintParentInfo)parentDbinfo).getTableInfo();
    final String schemaName = parentDbinfo.getSchemaName();
    final PreparedStatement pstmt = conn.prepareStatement(SQL);
   
    try  {
View Full Code Here

TOP

Related Classes of net.sourceforge.squirrel_sql.fw.sql.SQLDatabaseMetaData

Copyright © 2018 www.massapicom. 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.