Skip to content

Commit

Permalink
[KYUUBI #2640] Implement TGetInfoType CLI_ODBC_KEYWORDS
Browse files Browse the repository at this point in the history
### _Why are the changes needed?_

Fix #2637

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2640 from pan3793/odbc.

Closes #2640

a798271 [Cheng Pan] Implement TGetInfoType CLI_ODBC_KEYWORDS

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
(cherry picked from commit 8de2f5f)
Signed-off-by: Cheng Pan <chengpan@apache.org>
  • Loading branch information
pan3793 committed May 13, 2022
1 parent a2c0f78 commit 5106738
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ abstract class AbstractSession(
case TGetInfoType.CLI_SERVER_NAME => TGetInfoValue.stringValue("Apache Kyuubi (Incubating)")
case TGetInfoType.CLI_DBMS_NAME => TGetInfoValue.stringValue("Apache Kyuubi (Incubating)")
case TGetInfoType.CLI_DBMS_VER => TGetInfoValue.stringValue(org.apache.kyuubi.KYUUBI_VERSION)
case TGetInfoType.CLI_ODBC_KEYWORDS => TGetInfoValue.stringValue("Unimplemented")
case TGetInfoType.CLI_MAX_COLUMN_NAME_LEN |
TGetInfoType.CLI_MAX_SCHEMA_NAME_LEN |
TGetInfoType.CLI_MAX_TABLE_NAME_LEN => TGetInfoValue.lenValue(128)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,8 @@ class TFrontendServiceSuite extends KyuubiFunSuite {
assert(client.GetInfo(req).getInfoValue.getStringValue === "Apache Kyuubi (Incubating)")
req.setInfoType(TGetInfoType.CLI_DBMS_NAME)
assert(client.GetInfo(req).getInfoValue.getStringValue === "Apache Kyuubi (Incubating)")
req.setInfoType(TGetInfoType.CLI_ODBC_KEYWORDS)
assert(client.GetInfo(req).getInfoValue.getStringValue === "Unimplemented")
req.setInfoType(TGetInfoType.CLI_MAX_COLUMN_NAME_LEN)
assert(client.GetInfo(req).getInfoValue.getLenValue === 128)
req.setInfoType(TGetInfoType.CLI_MAX_SCHEMA_NAME_LEN)
Expand Down

0 comments on commit 5106738

Please sign in to comment.