This is an automated email from the ASF dual-hosted git repository.

curth pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-adbc.git


The following commit(s) were added to refs/heads/main by this push:
     new a56528c69 fix(csharp/src/Drivers/Databricks): Set 
GetObjectsPatternsRequireLowerCase true (#3131)
a56528c69 is described below

commit a56528c693d35bd70254dcbc5f20c2609bd7df89
Author: Jacky Hu <[email protected]>
AuthorDate: Thu Jul 10 12:03:16 2025 -0700

    fix(csharp/src/Drivers/Databricks): Set GetObjectsPatternsRequireLowerCase 
true (#3131)
    
    ## Motivation
    
    The default value of `GetObjectsPatternsRequireLowerCase` of
    `DatabricksConnection` is `false` (inherit from `SparkConnection`, see
    
[here](https://github.com/apache/arrow-adbc/blob/main/csharp/src/Drivers/Apache/Spark/SparkConnection.cs#L116)),
    so when it is called with table pattern in uppercase as below, it does
    not return all the tables start with `test` and fails some test cases
    
[DriverTest:GetObjectsTablesTest](https://github.com/apache/arrow-adbc/blob/main/csharp/test/Drivers/Apache/Common/DriverTests.cs#L308)
    (when `tableNamePattern` is uppercase)
    
    ```
    Connection.GetObjects(
                        depth: AdbcConnection.GetObjectsDepth.Tables,
                        catalogPattern = "catalog1",
                        dbSchemaPattern = "default",
                        tableNamePattern = "TEST%");
    ```
    
    ## Changes
    - Override `GetObjectsPatternsRequireLowerCase` to `true` in
    `DatabricksConnection`
    
    ## Test
    
    Apache.Arrow.Adbc.Tests.Drivers.Databricks.DriverTests.CanGetObjectsTables
---
 csharp/src/Drivers/Databricks/DatabricksConnection.cs | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/csharp/src/Drivers/Databricks/DatabricksConnection.cs 
b/csharp/src/Drivers/Databricks/DatabricksConnection.cs
index c292129cf..0d5839bb0 100644
--- a/csharp/src/Drivers/Databricks/DatabricksConnection.cs
+++ b/csharp/src/Drivers/Databricks/DatabricksConnection.cs
@@ -360,6 +360,8 @@ namespace Apache.Arrow.Adbc.Drivers.Databricks
 
         protected internal override bool AreResultsAvailableDirectly => 
_enableDirectResults;
 
+        protected override bool GetObjectsPatternsRequireLowerCase => true;
+
         protected override void SetDirectResults(TGetColumnsReq request) => 
request.GetDirectResults = defaultGetDirectResults;
 
         protected override void SetDirectResults(TGetCatalogsReq request) => 
request.GetDirectResults = defaultGetDirectResults;

Reply via email to