alinaliBQ opened a new issue, #47237:
URL: https://github.com/apache/arrow/issues/47237

   ### Describe the enhancement requested
   
   Current behavior: 
   `flightsql-odbc` backend doesn't differentiate between `SQL_PRED_CHAR`, 
`SQL_PRED_BASIC`, and `SQL_SEARCHABLE`. `SQL_SEARCHABLE` is returned by default 
when the Arrow data type is searchable. This causes a problem because types 
like `bit` is searchable, but it is generally not supported in `LIKE` clause, 
so `SQL_PRED_BASIC` is more appropriate compared to `SQL_SEARCHABLE`. And 
returning `SQL_SEARCHABLE` for `bit` would be misleading. 
   
   This is a minor issue that's not impacting most BI tools. 
   
https://github.com/apache/arrow/blob/596a60fa00d9d88bbe562602543474e8faf9ea5a/cpp/src/arrow/flight/sql/odbc/flight_sql/flight_sql_statement_get_type_info.cc#L117-L118
   
   SQLGetTypeInfo spec for reference on definitions of `SQL_PRED_*`: 
https://learn.microsoft.com/en-us/sql/odbc/reference/syntax/SQLGetTypeInfo-function?view=sql-server-ver17
   
   AC:
   - When a data type is `searchable`, the ODBC should return `SQL_PRED_CHAR` 
or `SQL_PRED_BASIC` for the appropriate data types
   
   
   -----
   Parent issue: https://github.com/apache/arrow/issues/30622
   
   
   ### Component(s)
   
   C++, FlightRPC


-- 
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: issues-unsubscr...@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to