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

SAP SQL Anywhere 17.0.11: Liquibase incorrectly reports that TIMESTAMP requested precision is longer than TIMESTAMP supported precision #3971

Closed
1 of 2 tasks
mkarg opened this issue Mar 17, 2023 · 6 comments · Fixed by #4422
Assignees
Labels
DBSQLAnywhere good first issue This issue is an easy starter project for new contributors. needs_guidance

Comments

@mkarg
Copy link
Contributor

mkarg commented Mar 17, 2023

Search first

  • I searched and no similar issues were found

Description

I am trying to generateChangeLog from a SAP SQL Anywhere 17.0.11 database which contains TIMESTAMP WITH TIME ZONE columns having a default of DEFAULT UTC TIMESTAMP.

Liquibase incorrectly complains that the supported precision is shorter than the requested precision:

liquibase.exception.LiquibaseException: liquibase.exception.CommandExecutionException: java.lang.RuntimeException: java.lang.RuntimeException: liquibase.exception.DatabaseIncapableOfOperation: Using a TIMESTAMP data type with a fractional precision of 33 is not supported on asany: A timestamp datatype with 33 fractional digits was requested, but SQL Anywhere only supports 9 digits.

The message was true for older versions of SQL Anywhere which did not support "WITH TIME ZONE", but since current versions support "WITH TIME ZONE" this message is wrong now.

Steps To Reproduce

generateChangeLog using SQL Anywhere 17.0.11 having a column with the definition TIMESTAMP WITH TIMEZONE DEFAULT UTC TIMESTAMP.

Expected/Desired Behavior

Successfully accepts both, the type TIMESTAMP WITH TIMEZONE and the default value UTC TIMESTAMP.

Liquibase Version

latest

Database Vendor & Version

SAP SQL Anywhere 17.0.11

Liquibase Integration

Maven Plugin

Liquibase Extensions

none

OS and/or Infrastructure Type/Provider

Windows 10

Additional Context

No response

Are you willing to submit a PR?

  • I'm willing to submit a PR (Thank you!)
@nvoxland
Copy link
Contributor

Thanks for the issue. There is similar "timestamp with time zone" logic for postgresql that will need to be adapted to sap sql now that it supports it.

@nvoxland nvoxland added the good first issue This issue is an easy starter project for new contributors. label Mar 23, 2023
@mkarg
Copy link
Contributor Author

mkarg commented Apr 25, 2023

There is similar "timestamp with time zone" logic for postgresql that will need to be adapted to sap sql now that it supports it.

Does "that need to be adapted" mean that a committer will work on it, or does it mean that the project team expects the reported (me) to provide that fix?

mkarg added a commit to mkarg/liquibase that referenced this issue Apr 26, 2023
… reports that TIMESTAMP requested precision is longer than TIMESTAMP supported precision
@mkarg
Copy link
Contributor Author

mkarg commented Apr 26, 2023

I have startet work in this issue in my private fork: https://github.com/mkarg/liquibase/tree/mkarg/sap-sql-anywhere-liquibase-3971. Comments very welcome! 😃

@MalloD12
Copy link
Contributor

Hi @mkarg, thank you for reporting this issue and for creating a PR for it. Is there anything we can do to help you to move forward with this PR?

@mkarg
Copy link
Contributor Author

mkarg commented Jun 23, 2023

Hi @mkarg, thank you for reporting this issue and for creating a PR for it. Is there anything we can do to help you to move forward with this PR?

Thank you for this kind offer, I really appreciate it. @filipelautert is already supporting me. Unfortunately I do not see how you can help right now, as the next step is that I need to check the JDBC driver's actual behavior. Once that is known, we can decide how to work around.

mkarg added a commit to mkarg/liquibase that referenced this issue Jun 26, 2023
… reports that TIMESTAMP requested precision is longer than TIMESTAMP supported precision
@MalloD12
Copy link
Contributor

Yeah, I talked with Filipe after posting my comment. Cool, if there is anything I can help with please let me know.

Thanks,
Daniel.

mkarg added a commit to mkarg/liquibase that referenced this issue Jun 26, 2023
… reports that TIMESTAMP requested precision is longer than TIMESTAMP supported precision
filipelautert pushed a commit that referenced this issue Jul 6, 2023
… that TIMESTAMP requested precision is longer than TIMESTAMP supported precision" (#4422)

* Fixed #3971: SAP SQL Anywhere 17.0.11: Liquibase incorrectly reports that TIMESTAMP requested precision is longer than TIMESTAMP supported precision

* Fixed Typo

There was a closing angle missing when fixing the merge conflict.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DBSQLAnywhere good first issue This issue is an easy starter project for new contributors. needs_guidance
Projects
Archived in project
5 participants