WillAyd commented on code in PR #1170:
URL: https://github.com/apache/arrow-adbc/pull/1170#discussion_r1348918872


##########
c/driver/postgresql/postgres_copy_reader.h:
##########
@@ -1172,6 +1172,44 @@ class PostgresCopyNetworkEndianFieldWriter : public 
PostgresCopyFieldWriter {
   }
 };
 
+class PostgresCopyFloatFieldWriter : public PostgresCopyFieldWriter {
+ public:
+  ArrowErrorCode Write(ArrowBuffer* buffer, int64_t index, ArrowError* error) 
override {
+    const int8_t is_null = ArrowArrayViewIsNull(array_view_, index);
+    const int32_t field_size_bytes = is_null ? -1 : sizeof(uint32_t);
+    NANOARROW_RETURN_NOT_OK(WriteChecked<int32_t>(buffer, field_size_bytes, 
error));
+    if (is_null) {
+      return ADBC_STATUS_OK;
+    }

Review Comment:
   Yea I can take a look at that - I think it will get repeated across every 
type



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to