lidavidm commented on code in PR #955:
URL: https://github.com/apache/arrow-adbc/pull/955#discussion_r1282338859


##########
c/driver/sqlite/sqlite.c:
##########
@@ -1025,6 +1027,46 @@ AdbcStatusCode SqliteStatementInitIngest(struct 
SqliteStatement* stmt,
       goto cleanup;
     }
 
+    int status =
+        ArrowSchemaViewInit(&view, stmt->binder.schema.children[i], 
&arrow_error);
+    if (status != 0) {
+      SetError(error, "Failed to parse schema for column %d: %s (%d): %s", i,
+               strerror(status), status, arrow_error.message);
+      code = ADBC_STATUS_INTERNAL;
+      goto cleanup;
+    }

Review Comment:
   for what it's worth, you could just create a view of the top-level schema 
and just use its children in the loop, though I suppose this gives a slightly 
nicer error message if one of the fields is invalid



-- 
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