flake8-sql icon indicating copy to clipboard operation
flake8-sql copied to clipboard

Flake8 plugin that checks SQL code against opinionated style rules

Results 7 flake8-sql issues
Sort by recently updated
recently updated
newest added

Running flake8 with flake8-sql on pre-commit CI is giving me the following error: ``` multiprocessing.pool.RemoteTraceback: """ Traceback (most recent call last): File "/usr/lib/python3.10/multiprocessing/pool.py", line 125, in worker result = (True,...

If flake8 is run on a file containing following code, errors listed below will get raised ```python def test(): """ Request osmcha analysis for changeset ids and update edits table...

#12 assumes that `end_lineno` will not be set for single-line strings. However, as of Python 3.9 (python/cpython@b7e9525f9c7ef02a1d2ad8253afdeb733b0951d4) these fields are instead defaulted to `None`. Also add testing for Python 3.9/3.10...

It looks like flake8-sql fails to parse queries built with f-strings (the same string with `.format()` works) Below is a compact example tested with: `python -m flake8 flake8_sql_check.py` ```py columns...

Hey @pgjones, How do I run this plugin so that Linting can take place fo specifically SQL? When I run using flake8 and put the rule e.g Q440 linting does...

This piece of code: ``` SELECT acfc.adcategoryid, acfc.targetmetadatadefinitionid FROM [adcategoryfiltercondition] acfc GROUP BY acfc.adcategoryid, acfc.targetmetadatadefinitionid HAVING acfc.targetmetadatadefinitionid IS NOT NULL ``` should be fine according to the style guide that...

Hey @pgjones I have this query ```sql SELECT EXISTS(SELECT 1 FROM table WHERE condition1 AND condition2) ``` and getting this Q449 warning: **Q449 token FROM should be aligned to the...