Search in sources :

Example 1 with KillStatement

use of io.crate.sql.tree.KillStatement in project crate by crate.

the class TestStatementBuilder method testKillAll.

@Test
public void testKillAll() {
    Statement stmt = SqlParser.createStatement("KILL ALL");
    assertThat(stmt, is(new KillStatement(null)));
}
Also used : KillStatement(io.crate.sql.tree.KillStatement) SetStatement(io.crate.sql.tree.SetStatement) CommitStatement(io.crate.sql.tree.CommitStatement) DeallocateStatement(io.crate.sql.tree.DeallocateStatement) BeginStatement(io.crate.sql.tree.BeginStatement) Statement(io.crate.sql.tree.Statement) KillStatement(io.crate.sql.tree.KillStatement) SetSessionAuthorizationStatement(io.crate.sql.tree.SetSessionAuthorizationStatement) Test(org.junit.Test)

Example 2 with KillStatement

use of io.crate.sql.tree.KillStatement in project crate by crate.

the class TestStatementBuilder method testKillJob.

@Test
public void testKillJob() {
    KillStatement stmt = (KillStatement) SqlParser.createStatement("KILL $1");
    assertThat(stmt.jobId(), is(notNullValue()));
}
Also used : KillStatement(io.crate.sql.tree.KillStatement) Test(org.junit.Test)

Aggregations

KillStatement (io.crate.sql.tree.KillStatement)2 Test (org.junit.Test)2 BeginStatement (io.crate.sql.tree.BeginStatement)1 CommitStatement (io.crate.sql.tree.CommitStatement)1 DeallocateStatement (io.crate.sql.tree.DeallocateStatement)1 SetSessionAuthorizationStatement (io.crate.sql.tree.SetSessionAuthorizationStatement)1 SetStatement (io.crate.sql.tree.SetStatement)1 Statement (io.crate.sql.tree.Statement)1