summaryrefslogtreecommitdiff
path: root/sqlparse/engine
Commit message (Collapse)AuthorAgeFilesLines
* Fixed bad parsing of create table statements that use lower caseSimon Heisterkamp2022-08-241-2/+2
|
* CREATE TABLE tbl AS SELECT should return get_alias() for its columnAki Ariga2022-08-241-1/+4
|
* Make tzcast grouping function less eagerErik Cederstrand2022-08-161-2/+9
|
* Update copyright notice.Andi Albrecht2020-10-074-4/+4
|
* Fix an issue with negative indexes causing IndexError in some cases.Andi Albrecht2020-09-301-0/+2
|
* Fix splitting of statements using CASE ... WHEN (fixes #580).Andi Albrecht2020-09-301-1/+1
|
* Don't flush token streams iff they only contain whitespace tokens (fixes #496).Andi Albrecht2020-09-131-1/+1
|
* Remove support for end-of-life PythonsJon Dufresne2020-08-314-6/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Python 2.7 and 3.4 are end-of-life. They are no longer receiving bug fixes, including for security issues. Python 2.7 went EOL on 2020-01-01 and 3.4 on 2019-03-18. For additional details on support Python versions, see: Supported: https://devguide.python.org/#status-of-python-branches EOL: https://devguide.python.org/devcycle/#end-of-life-branches Removing support for EOL Pythons will reduce testing and maintenance resources while allowing the library to move towards modern Python 3. Using pypinfo, we can show the PyPI download statistics, showing less than 10% of users are using Python 2.7. | python_version | percent | download_count | | -------------- | ------: | -------------: | | 3.7 | 45.36% | 3,056,010 | | 3.6 | 26.46% | 1,782,778 | | 3.8 | 12.22% | 823,213 | | 2.7 | 9.97% | 671,459 | | 3.5 | 5.86% | 394,846 | | 3.4 | 0.10% | 6,700 | | 3.9 | 0.03% | 2,346 | | 2.6 | 0.00% | 57 | | 3.3 | 0.00% | 21 | | 3.10 | 0.00% | 6 | | Total | | 6,737,436 | Library users who continue to use Python 2.7 will still be able to install previous versions of sqlparse. Compatibility shims have been dropped, simplifying the code. Using pyupgrade, the codebase has been updated to take advantage of modern syntax <https://github.com/asottile/pyupgrade>. The wheel is no longer marked as "universal" as it is now Python 3 only.
* [fix] Adding TypedLiteral to comparisonJohn Bodley2020-03-291-1/+1
|
* [grouping] group_as() no longer groups AS CTELikai Liu2020-02-021-1/+1
| | | | | | | | | | | | | | | | | This patch changes the grouping of AS so that: Foo AS WITH bar AS 1 SELECT 2 with no longer be grouped as: [Identifier[Foo, AS, WITH, Identifier[Bar AS 1]], SELECT, 2] but will be grouped as: [Identifier[Foo], AS, WITH, Identifier[Bar AS 1], SELECT, 2] This fixes the parsing of CREATE TABLE new_table AS WITH ... so the rest of the tokens after AS are parsed the same as a bare WITH.
* [fix] Fixing typed literal regressionJohn Bodley2020-02-021-1/+1
|
* Stabilize grouping engine when parsing invalid SQL statements.Andreas Albrecht2020-01-061-2/+2
| | | | | It's just to make sure, that the comparison returns a valid result when feed with invalid SQL statements.
* Code cleanup.Andreas Albrecht2019-10-202-4/+8
|
* support typed literals (if that's what they're called)Dvořák Václav2019-10-201-2/+32
|
* Add support for time zone casts (fixes #489).Andi Albrecht2019-05-161-0/+14
|
* Fixes #485William Ivanski2019-04-171-1/+1
|
* Fixes #485William Ivanski2019-04-171-1/+0
|
* Fixes #485William Ivanski2019-04-171-6/+9
|
* Fix formatting on INSERT (fixes #329)Fredy Wijaya2019-03-101-0/+13
| | | | | | | | | | | | | | | | | | | | This patch fixes the formatting on INSERT by creating a new instance of sql.Values to group all the values. SQL: insert into foo values (1, 'foo'), (2, 'bar'), (3, 'baz') Before: insert into foo values (1, 'foo'), (2, 'bar'), (3, 'baz') After: insert into foo values (1, 'foo'), (2, 'bar'), (3, 'baz')
* Code cleanup.Andreas Albrecht2019-03-102-4/+4
|
* Update copyright header (fixes #372).Andi Albrecht2018-07-314-4/+8
|
* Fix typostypoVictor Uriarte2017-11-292-6/+6
|
* Fix handling of semicolon when grouping assignments (fixes #359).Andi Albrecht2017-09-241-1/+1
| | | | | | When grouping assignments that contain a semicolon itself, the engine was too greedy. Assignments with semicolon were introduced in 691c0400e5a7d8229b7dce09bf47176539add328.
* Re-order parsing so that comparisons are seens as identifiers (fixes #327).Andi Albrecht2017-04-181-2/+2
|
* Fix special case for #284 when statement starts with orphaned AS.Andi Albrecht2016-10-241-1/+1
|
* Handle operator grouping after identifying typecasts (fixes #297).Andi Albrecht2016-10-011-1/+1
|
* Correct license link (fixes #288).Andi Albrecht2016-09-144-4/+4
|
* Merge pull request #285 from vmuriart/unify_naming_schemaAndi Albrecht2016-08-241-5/+5
|\ | | | | Unify_naming_schema. Closes #283
| * Unify_naming_schema. Closes #283Victor Uriarte2016-08-221-5/+5
| |
* | Fix #284 as groupingVictor Uriarte2016-08-221-1/+1
|/
* Remove PostgreSQL builtin from _change_splitlevel.Victor Uriarte2016-08-131-18/+0
| | | | No longer needed as internals are now being treated as a string literal
* Previous fix for period failed when another token (non-groupable) followed.Victor Uriarte2016-06-191-3/+8
|
* Revert behavior of dangling period(hanging schema qualifier)Victor Uriarte2016-06-181-2/+2
| | | | | | Related to #261. Reverting to previous behavior until a way to handle behavior/grouping of invalid sql is agreed upon.
* Misc. small code clean-up/commentsVictor Uriarte2016-06-181-3/+2
|
* Change group_matching back to idxVictor Uriarte2016-06-151-6/+16
|
* remove group left_rightVictor Uriarte2016-06-151-27/+0
|
* Change grouping from _left_right to _groupVictor Uriarte2016-06-151-18/+71
|
* remove extra recurse and rename varsVictor Uriarte2016-06-151-30/+43
| | | | | # Conflicts: # sqlparse/engine/grouping.py
* Refactor _group's prev token logicVictor Uriarte2016-06-151-13/+11
|
* Reduce calls by _group to get tk idxVictor Uriarte2016-06-151-4/+15
|
* Re-Write grouping functionsVictor Uriarte2016-06-151-29/+47
|
* Reorder grouping code and func call orderVictor Uriarte2016-06-151-67/+66
| | | | Remove repeated for-each/for grouping
* Make use of token_index more obviousVictor Uriarte2016-06-151-4/+6
|
* Normalize behavior between token_next and token_next_byVictor Uriarte2016-06-151-13/+12
| | | | both will now return the "next" token and not itself when passing own index
* Rename token_idx_ funcs to simply token_ funcsVictor Uriarte2016-06-151-50/+50
|
* Change token_ funcs to token_idx funcsVictor Uriarte2016-06-151-52/+59
|
* Change argument order to match order of all other functionsVictor Uriarte2016-06-141-1/+2
|
* Refactor _group_matchingVictor Uriarte2016-06-141-17/+13
|
* Apply alt style for grouping left/rightVictor Uriarte2016-06-141-7/+9
|
* Reapply fix for case within paranthesisVictor Uriarte2016-06-141-1/+3
|