-
Notifications
You must be signed in to change notification settings - Fork 42
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
Issue #196: Add the 'name' to the 'reference' block for FOREIGN KEY constraints #224
Conversation
@@ -960,8 +967,6 @@ def set_constraint( | |||
target_dict["constraints"] = {} | |||
if not target_dict["constraints"].get(_type): | |||
target_dict["constraints"][_type] = [] | |||
if "name" in constraint: |
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.
i don't know why these were here, but they were breaking my references. Removing them did not break any other tests, so i think that maybe they were unnecessary?
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.
possible, it is redunant code, looks like I changed some logic, but forgot to remove this
@@ -644,7 +644,9 @@ def test_double_single_quotes(): | |||
|
|||
def test_autoincrement_order(): | |||
# test for https://github.com/xnuinside/simple-ddl-parser/issues/208 | |||
ddl = """CREATE TABLE table (surrogatekey_SK NUMBER(38,0) NOT NULL autoincrement start 1 increment 1 ORDER COMMENT 'Record Identification Number Ordered')""" | |||
ddl = """CREATE TABLE table ( |
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.
they changes in this file are all from the pre-commit hook.
@cfhowes thanks for the PR again ! :) |
@cfhowes changes released in version 0.32.0 |
As requested in #196, added
name
to thereferences
block of constraints. This should allow users of the parsed output to be able to associate the FOREIGN KEY with the proper column in the table.