h2/src/test/org/h2/test/todo/TestLinkedTableFullCondition.java
/**
     * Run just this test.
     *
     * @param args ignored
     */
Run just this test.
@param args ignored
Run just this test . @param args ignored
public static void main(String... args) throws Exception {
        DeleteDbFiles.execute("data", null, true);
        Class.forName("org.h2.Driver");
        Connection conn;
        conn = DriverManager.getConnection("jdbc:h2:data/test");
        Statement stat = conn.createStatement();
        stat.execute("create table test(id int primary key, name varchar)");
        stat.execute("insert into test values(1, 'Hello')");
        stat.execute("insert into test values(2, 'World')");
        stat.execute("create linked table test_link('', 'jdbc:h2:data/test', '', '', 'TEST')");
        stat.execute("set trace_level_system_out 2");
        stat.execute("select * from test_link where id = 1 and name = 'Hello'");
        conn.close();
    }
public static void main ( String ... args ) throws Exception { DeleteDbFiles . execute ( "data" , null , true ) ; Class . forName ( "org.h2.Driver" ) ; Connection conn ; conn = DriverManager . getConnection ( "jdbc:h2:data/test" ) ; Statement stat = conn . createStatement ( ) ; stat . execute ( "create table test(id int primary key, name varchar)" ) ; stat . execute ( "insert into test values(1, 'Hello')" ) ; stat . execute ( "insert into test values(2, 'World')" ) ; stat . execute ( "create linked table test_link('', 'jdbc:h2:data/test', '', '', 'TEST')" ) ; stat . execute ( "set trace_level_system_out 2" ) ; stat . execute ( "select * from test_link where id = 1 and name = 'Hello'" ) ; conn . close ( ) ; }
Run just this test.
Run just this test .
// the query sent to the linked database is // SELECT * FROM PUBLIC.TEST T WHERE ID>=? AND ID<=? {1: 1, 2: 1}; // it should also include AND NAME='Hello'