Releases: xnuinside/simple-ddl-parser
Releases · xnuinside/simple-ddl-parser
0.28.0 - AUTO_INCREMENT & floats & other bug fixes
v0.28.0
Important Changes (Pay attention):
- Because of parsing now AUTO_INCREMENT as a separate property of column previous output changed.
Previously it was parsed as a part of type like: 'INT AUTO_INCREMENT'.
Now type will be only 'INT', but in column property you will see 'autoincrement': True.
Amazing innovations:
- It's is weird to write in Changelog, but only in version 0.28.0 I recognise that floats that not supported by parser & it was fixed.
Thanks for the sample in the issue: #163
Improvements:
MariaDB:
- Added support for MariaDB AUTO_INCREMENT (from ddl here - #144)
If column is Auto Incremented - it indicated as 'autoincrement': True in column definition
Common:
- Added parsing for multiline comments in DDL with
/* */
syntax. - Comments from DDL now all placed in 'comments' keyword if you use
group_by_type=
arg in parser. - Added argument 'parser_settings={}' (dict type) in method parse_from_file() - this way you can pass any arguments that you want to DDLParser (& that supported by it)
So, if you want to set log_level=logging.WARNING for parser - just use it as:
parse_from_file('path_to_file', parser_settings={'log_level': logging.WARNING}). For issue: #160
v0.27.0 - Fixes & improvements
v0.27.0
Fixes:
Improvements:
- Added support for '*' in size column (ORACLE dialect) - #151
- Added arg 'debug' to parser, works same way as 'silent' - to get more clear error output.
New features:
v0.26.3 - Few Improvements
v0.26.2 - SNOWFLAKE dialect fixes
v0.26.2
Fixes:
- Fixed a huge bug for incorrect parsing lines with 'USE' & 'GO' strings inside.
- Fixed parsing for CREATE SCHEMA for Snowlake & Oracle DDLs
Improvements:
- Added COMMENT statement for CREATE TABLE ddl (for SNOWFLAKE dialect support)
- Added COMMENT statement for CREATE SCHEMA ddl (for SNOWFLAKE dialect support)
v0.26.0 - Fixes & Improvements release
Improvements:
- Added more explicit debug message on Statement errors - #116
- Added support for "USING INDEX TABLESPACE" statement in ALTER - #119
- Added support for IN statements in CHECKS - #121
New features:
- Support SparkSQL USING - #117
Updates initiated by ticket #120: - In Parser you can use argument json_dump=True in method .run() if you want get result in JSON format.
- README updated
Fixes:
v0.25.0 New flags in Parser: normalize_names=True and silent=False
v0.25.0
Fixes:
- Fix for issue with 'at time zone' #112
New features:
- Added flag to raise errors if parser cannot parse statement DDLParser(.., silent=False) - #109
- Added flag to DDLParser(.., normalize_names=True) that change output of parser:
if flag is True (default 'False') then all identifiers will be returned without '[', '"' and other delimeters that used in different SQL dialects to separate custom names from reserverd words & statements.
For example, if flag set 'True' and you pass this input:
CREATE TABLE [dbo].[TO_Requests](
[Request_ID] [int] IDENTITY(1,1) NOT NULL,
[user_id] [int]
In output you will have names like 'dbo' and 'TO_Requests', not '[dbo]' and '[TO_Requests]'.
0.24.1 if_not_exists added to output
Fixes:
HQL:
- fields_terminated_by now parses , as "','", not as '' previously
Common:
- To output added 'if_not_exists' field in result to get availability 1-to-1 re-create ddl by metadata.
0.24.0 HQL support for CLUSTERED BY, INTO .. BUCKETS and more
Fixes:
HQL:
- More then 2 tblproperties now are parsed correctly #104
Common:
- 'set' in lower case now also parsed validly.
- Now names like 'schema', 'database', 'table' can be used as names in CREATE DABASE | SCHEMA | TABLESPACE | DOMAIN | TYPE statements and after INDEX and CONSTRAINT.
- Creation of empty tables also parsed correctly (like CREATE Table table;).
New Statements Support:
HQL:
- Added support for CLUSTERED BY - #103
- Added support for INTO ... BUCKETS
- CREATE REMOTE DATABASE | SCHEMA
0.23.0 - ALTER TABLE ONLY, ALTER TABLE IF EXISTS + refactoring
v0.23.0
Big refactoring: less code complexity & increase code coverage. Radon added to pre-commit hooks.
Fixes:
- Fix for issue with ALTER UNIQUE - #101
New Features
- SQL Comments string from DDL now parsed to "comments" key in output.
PostgreSQL:
- Added support for ALTER TABLE ONLY | ALTER TABLE IF EXISTS
0.22.6 Improvements for PostgreSQL
v0.22.6
Fixes:
- Fix for: #99
Issue with pg_dump output:
Now SETs with = and ; in them are parsed normally.
Improvements:
- Added support for types with 3+ words like PostgreSQL "timestamp without time zone"
- Added support for SEQUENCE properties with 'NO' word like NO MAXVALUE.
It's parsed now as 'maxvalue': False}