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

Data Type Mismatch Issue After Upgrade from 1.6.0 to 1.7.2 #16931

Open
naomi-earle opened this issue Oct 28, 2024 · 4 comments
Open

Data Type Mismatch Issue After Upgrade from 1.6.0 to 1.7.2 #16931

naomi-earle opened this issue Oct 28, 2024 · 4 comments

Comments

@naomi-earle
Copy link

Describe the bug

After upgrading a project from Orchard Core version 1.6.0 to 1.7.2, we noticed that data types for certain fields were changed from int to long starting with version 1.7.0. However, there was no migration step provided to alter the existing database columns accordingly.

When creating a new database from versions 1.7.0 or 1.7.2, the columns are correctly set to bigint, but our existing database retains the int type. While it appears that there are work-arounds in place and backward compatibility has been addressed, we are concerned that this mismatch could lead to bugs or issues in future updates.

Orchard Core version

1.7.2 (upgraded from 1.6.0)

To Reproduce

  1. Upgrade an Orchard Core project with a database to 1.7.0 from an earlier version.
  2. Inspect the data types of columns in the existing database.
  3. Compare with a newly created database from version 1.7.0.

Expected behavior

Data types for all relevant columns in the existing database should match those in the new database, specifically, being of type bigint instead of int.

Additional context

I found a related bug report from June (#16580) that addresses similar concerns, and a fix was implemented (https://github.com/OrchardCMS/OrchardCore/pull/16234/files). However, without a migration step for existing databases, I am worried about ongoing issues stemming from this data type mismatch.

Copy link
Contributor

Thank you for submitting your first issue, awesome! 🚀 We're thrilled to receive your input. If you haven't completed the template yet, please take a moment to do so. This ensures that we fully understand your feature request or bug report. On what happens next, see the docs.

If you like Orchard Core, please star our repo and join our community channels.

@MikeAlhayek
Copy link
Member

After upgrading a project from Orchard Core version 1.6.0 to 1.7.2, we noticed that data types for certain fields were changed from int to long starting with version 1.7.0. However, there was no migration step provided to alter the existing database columns accordingly.

You should not run into a mismatch. If your site was created before 1.7 release, then it'll always be int even if you create new tables. However, if your site was created 1.7+, then the new default will be bigint.

Are you seeing a specific issue?

@sebastienros
Copy link
Member

Copy link
Contributor

It seems that this issue didn't really move for quite a while despite us asking the author for further feedback. Is this something you'd like to revisit any time soon or should we close? Please reply.

@github-actions github-actions bot added the stale label Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants