Oracle JDBC and Oracle CHAR data type

If you want

stmt.setString(1, "a");    // This won't return any records

to return a record, try

conn.prepareStatement("select * from x where c = cast(? as char(4))")

Leave a Comment