Skip to content

Commit

Permalink
Renamed addBitType to registerType
Browse files Browse the repository at this point in the history
  • Loading branch information
ankane committed Jun 26, 2024
1 parent 86af42d commit 595a00d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main/java/com/pgvector/PGbit.java
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ public boolean[] toArray() {
* @param conn connection
* @throws SQLException exception
*/
public static void addBitType(Connection conn) throws SQLException {
public static void registerType(Connection conn) throws SQLException {
conn.unwrap(PGConnection.class).addDataType("bit", PGbit.class);
}
}
2 changes: 1 addition & 1 deletion src/test/java/com/pgvector/JDBCJavaTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ void bitExample(boolean readBinary) throws SQLException {
setupStmt.executeUpdate("CREATE EXTENSION IF NOT EXISTS vector");
setupStmt.executeUpdate("DROP TABLE IF EXISTS jdbc_items");

PGbit.addBitType(conn);
PGbit.registerType(conn);

Statement createStmt = conn.createStatement();
createStmt.executeUpdate("CREATE TABLE jdbc_items (id bigserial PRIMARY KEY, embedding bit(9))");
Expand Down

0 comments on commit 595a00d

Please sign in to comment.