-
Notifications
You must be signed in to change notification settings - Fork 4
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
adding normalize-case option to databricks labs lsql fmt cmd #254
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
✅ 34/34 passed, 2 flaky, 3 skipped, 46m54s total Flaky tests:
Running from acceptance #354 |
nfx
approved these changes
Aug 24, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
nfx
added a commit
that referenced
this pull request
Aug 26, 2024
* Added design for filter file ([#251](#251)). A new feature has been added to enable the creation of filters for multiple widgets in a dashboard using a `.filter.json` file. This file allows users to specify columns to be filtered, the filter type, title, description, order, and a unique ID for each filter. Both the `column` and `columns` flags are supported, with the former taking a single string and the latter taking a list of strings. The filter type can be set to a drop-down menu or another type as desired. The `.filter.json` file schema also supports optional `title` and `description` strings, as well as `order` and `ID` flags. An example of a `.filter.json` file is provided in the commit message. Additionally, the `dashboard.yml` file documentation has been updated to include information on how to use the new `.filter.json` file. * adding normalize-case option to databricks labs lsql fmt cmd ([#254](#254)). In this open-source library release, the `databricks labs lsql` tool's `fmt` command now supports a new flag, `normalize-case`. This flag allows users to control the normalization of query text to lowercase, providing more flexibility when formatting SQL queries. By default, query text is still normalized to lowercase, but users can now prevent this behavior by setting the `normalize-case` flag to `False`. This change addresses an issue where some queries are case sensitive, such as those using map field keys in UCX dashboards. Additionally, a new parameter `normalize_case` has been added to the `format` method in the `dashboards.py` file, with updated method documentation. A new test function, `test_query_formats_no_normalize()`, has also been included to ensure consistent formatter behavior.
Merged
nfx
added a commit
that referenced
this pull request
Aug 26, 2024
* Added design for filter file ([#251](#251)). A new feature has been added to enable the creation of filters for multiple widgets in a dashboard using a `.filter.json` file. This file allows users to specify columns to be filtered, the filter type, title, description, order, and a unique ID for each filter. Both the `column` and `columns` flags are supported, with the former taking a single string and the latter taking a list of strings. The filter type can be set to a drop-down menu or another type as desired. The `.filter.json` file schema also supports optional `title` and `description` strings, as well as `order` and `ID` flags. An example of a `.filter.json` file is provided in the commit message. Additionally, the `dashboard.yml` file documentation has been updated to include information on how to use the new `.filter.json` file. * adding normalize-case option to databricks labs lsql fmt cmd ([#254](#254)). In this open-source library release, the `databricks labs lsql` tool's `fmt` command now supports a new flag, `normalize-case`. This flag allows users to control the normalization of query text to lowercase, providing more flexibility when formatting SQL queries. By default, query text is still normalized to lowercase, but users can now prevent this behavior by setting the `normalize-case` flag to `False`. This change addresses an issue where some queries are case sensitive, such as those using map field keys in UCX dashboards. Additionally, a new parameter `normalize_case` has been added to the `format` method in the `dashboards.py` file, with updated method documentation. A new test function, `test_query_formats_no_normalize()`, has also been included to ensure consistent formatter behavior.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
databricks labs lsql fmt cmd be defaults normalizes the query to lower case. Some queries are case sensitive
(ex UCX dashboard using map field keys)
This PR adds a parameter normalize-case to the fmt cli cmd to allow user to not normalize the query text (default would be to normalize as before)
Resolves #253