Package org.apache.hadoop.hbase.hbql.client

Examples of org.apache.hadoop.hbase.hbql.client.HConnection.dropTable()


        assertFalse(connection.tableExists("zzz"));

        String tableName = "tabletest1";
        if (connection.tableExists(tableName)) {
            connection.disableTable(tableName);
            connection.dropTable(tableName);
        }
        assertFalse(connection.tableExists(tableName));
        connection.execute("CREATE TABLE " + tableName + " (family1(), family2(), family3())");
        assertTrue(connection.tableExists(tableName));
        HTableDescriptor table = connection.getHTableDescriptor(tableName);
View Full Code Here


        assertTrue(table.hasFamily("family3".getBytes()));

        assertTrue(table.getNameAsString().equals(tableName));

        connection.disableTable(tableName);
        connection.dropTable(tableName);

        assertFalse(connection.mappingExists(tableName));
    }

    @Test
View Full Code Here

        HConnection connection = HConnectionManager.newConnection();

        String tableName = "tabletest1";
        if (connection.tableExists(tableName)) {
            connection.disableTable(tableName);
            connection.dropTable(tableName);
        }
        assertFalse(connection.tableExists(tableName));
        connection.execute("CREATE TABLE " + tableName
                           + " (family1 ("
                           + "MAX_VERSIONS:  12, "
View Full Code Here

        assertTrue(family.getCompressionType() == Compression.Algorithm.GZ);
        assertTrue(family.isInMemory());
        assertTrue(family.getTimeToLive() == 440);

        connection.disableTable(tableName);
        connection.dropTable(tableName);

        assertFalse(connection.mappingExists(tableName));
    }
}
View Full Code Here

        HConnection conn = HConnectionManager.newConnection();
        conn.execute("DROP TABLE foo");

        // Or using the API
        conn.dropTable("foo");

        // END SNIPPET: drop-table

    }
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.