Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Sql Server Connector to Support Case-Sensitive Collation #2629

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Trianz-Akshay
Copy link
Contributor

Issue #, if available:

  1. Invalid object name SYS.COLUMNS error occurs in Sql server Connector when case-sensitive collation is enabled.
  2. Unable to query uppercase table names when case-sensitive collation is enabled.

Description of changes:
Uppercase SYS.COLUMNS system view is not available in Sql Server when case-sensitive collation is enabled. Changed it to lowercase sys.columns and other respective queries(partition).
Added a method getExactCaseObjectName() which retrieves the exact schema and table name from Sql Server instead of converting it to uppercase.

Please find attached functional test results.
SQLSERVER_FUNCTIONAL_TEST.csv

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Copy link

codecov bot commented Feb 28, 2025

Codecov Report

Attention: Patch coverage is 69.51220% with 25 lines in your changes missing coverage. Please review.

Project coverage is 61.14%. Comparing base (f3521ad) to head (495f4fc).
Report is 94 commits behind head on master.

Files with missing lines Patch % Lines
...rs/sqlserver/SqlServerCaseInsensitiveResolver.java 77.04% 8 Missing and 6 partials ⚠️
...connectors/sqlserver/SqlServerMetadataHandler.java 47.61% 10 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #2629      +/-   ##
============================================
+ Coverage     60.68%   61.14%   +0.45%     
- Complexity     3871     3929      +58     
============================================
  Files           593      594       +1     
  Lines         22130    22354     +224     
  Branches       2732     2766      +34     
============================================
+ Hits          13430    13668     +238     
+ Misses         7398     7348      -50     
- Partials       1302     1338      +36     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant