sqlparse icon indicating copy to clipboard operation
sqlparse copied to clipboard

[fix] issue262 fixing SQL-Hint deleting when clearing script from comments

Open skryzh opened this issue 2 years ago • 1 comments

#Fixing SQL-Hint deleting when clearing script from comments #262

What is done:

  1. Added checking token type for Token.Comment.Multiline.Hint and Token.Comment.Single.Hint
  2. Added some tests for covering basic behavior
  3. Checked w/ tests from project
  4. Checked on production SQL scripts
  5. Checked as part of Airflow engine, because this library is used for splitting SQL statements before execute. And seems like this helped and Hints are working now.

Before submitting your pull request please have a look at the following checklist:

  • [x] ran the tests (pytest)
  • [x] all style issues addressed (flake8)
  • [x] your changes are covered by tests
  • [x] your changes are documented, if needed

In addition, please take care to provide a proper description on what your change does, fixes or achieves when submitting the pull request.

skryzh avatar Oct 18 '24 12:10 skryzh

Hi, @andialbrecht! Please consider to review this pr, for our project it is a vital to use SQL-Hints to help Vertica increase performance w/ complex scripts

skryzh avatar Oct 18 '24 12:10 skryzh

It's ok, same :D

skryzh avatar Nov 14 '24 09:11 skryzh