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


##########
c/validation/adbc_validation.cc:
##########
@@ -430,6 +430,20 @@ void ConnectionTest::TestMetadataGetTableSchema() {
                                     {"strings", NANOARROW_TYPE_STRING, 
NULLABLE}}));
 }
 
+void ConnectionTest::TestMetadataGetTableSchemaEscaping() {
+  if (!quirks()->supports_bulk_ingest(ADBC_INGEST_OPTION_MODE_CREATE)) {
+    GTEST_SKIP();
+  }
+  ASSERT_THAT(AdbcConnectionNew(&connection, &error), IsOkStatus(&error));
+  ASSERT_THAT(AdbcConnectionInit(&connection, &database, &error), 
IsOkStatus(&error));
+
+  Handle<ArrowSchema> schema;
+  ASSERT_NE(AdbcConnectionGetTableSchema(&connection, /*catalog=*/nullptr,
+                                         /*db_schema=*/nullptr, "(SELECT 
CURRENT_TIME)",
+                                         &schema.value, &error),
+            ADBC_STATUS_OK);

Review Comment:
   I think NOT_FOUND makes more sense. In Postgres you can check the SQLSTATE, 
that's what I did when I fixed up something similar to this earlier



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