Skip to content
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

Allows createSequence field "dataType" to be use with DB2 as the database supports it. #3328

Merged

Conversation

filipelautert
Copy link
Collaborator

Impact

  • Bug fix (non-breaking change which fixes expected existing functionality)
  • Enhancement/New feature (adds functionality without impacting existing logic)
  • Breaking change (fix or feature that would cause existing functionality to change)

Description

As per documentation DB2 documentation (https://www.ibm.com/docs/en/db2/9.7?topic=statements-create-sequence) , dataType parameter is supported by create sequence on DB2.

This PR just removes DB2 from the "blacklist" of "dataType" and adds an integration test to validate that.

@filipelautert filipelautert linked an issue Sep 30, 2022 that may be closed by this pull request
@github-actions
Copy link

github-actions bot commented Sep 30, 2022

Unit Test Results

  4 668 files  ±0    4 668 suites  ±0   33m 22s ⏱️ -15s
  4 609 tests ±0    4 380 ✔️ ±0     229 💤 ±0  0 ±0 
54 516 runs  ±0  49 448 ✔️ ±0  5 068 💤 ±0  0 ±0 

Results for commit 45501b0. ± Comparison against base commit 59ca536.

♻️ This comment has been updated with latest results.

@filipelautert filipelautert force-pushed the 2254-support-datatype-for-createsequence-on-db2luw branch from 153ce03 to 45501b0 Compare September 30, 2022 19:04
Copy link
Contributor

@nvoxland nvoxland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code review:

Things to be aware of:

  • Apparently the datatype syntax was valid for db2, we just hadn't tested it
  • Added integration test to verify it for db2 plus all database types that support it
  • Only impacts db2 people using dataType on createSequence

Things to worry about:

  • Nothing

@XDelphiGrl
Copy link
Contributor

The default database for branch runs of the functional tests is against Postgres. I'm running a build that includes DB2.
Link to Internal Builds

Copy link
Contributor

@XDelphiGrl XDelphiGrl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR extends Liquibase to support DB2 sequences defined with a datatype. For example, Liquibase will now snapshot (and generate-changelog/diff-changelog) a DB2 sequence such as:

CREATE SEQUENCE ORG_SEQ AS BIGINT START WITH 1 INCREMENT BY 1
  • New integration test added (where the dataType specified is 'INT').
  • Functional tests for DB2 passing on this branch.
  • No additional testing required.

APPROVED

@nvoxland nvoxland merged commit c3c1a53 into master Nov 8, 2022
@nvoxland nvoxland deleted the 2254-support-datatype-for-createsequence-on-db2luw branch November 8, 2022 07:04
@kevin-atx kevin-atx added this to the 1NEXT milestone Nov 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Support dataType for createSequence on DB2LUW
5 participants