use of io.crate.sql.tree.ShowCreateTable in project crate by crate.
the class TestStatementBuilder method testShowCreateTable.
@Test
public void testShowCreateTable() {
Statement stmt = SqlParser.createStatement("SHOW CREATE TABLE foo");
assertTrue(stmt instanceof ShowCreateTable);
assertEquals(((ShowCreateTable) stmt).table().getName().toString(), "foo");
stmt = SqlParser.createStatement("SHOW CREATE TABLE my_schema.foo");
assertEquals(((ShowCreateTable) stmt).table().getName().toString(), "my_schema.foo");
}
Aggregations