We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 427a19d commit d0666b5Copy full SHA for d0666b5
examples/loading/src/main/java/com/example/Example.java
@@ -41,13 +41,13 @@ public static void main(String[] args) throws SQLException {
41
// TODO use binary format
42
CopyIn copyIn = copyManager.copyIn("COPY items (embedding) FROM STDIN");
43
for (int i = 0; i < rows; i++) {
44
- if (i % 10000 == 0) {
45
- System.out.print(".");
46
- }
47
-
48
PGvector embedding = new PGvector(embeddings.get(i));
49
byte[] bytes = (embedding.getValue() + "\n").getBytes();
50
copyIn.writeToCopy(bytes, 0, bytes.length);
+
+ if (i % 10000 == 0) {
+ System.out.print(".");
+ }
51
}
52
copyIn.endCopy();
53
0 commit comments