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

Add configuration option to enable or disable foreign keys check for all 4 types of database connections #883

Merged
merged 1 commit into from
Jun 9, 2024

Conversation

martinszemitis
Copy link
Contributor

Problem:
When defining migrations for SQLite and, for example, setting cascading on delete it dosn't work as foreign keys are not enabled. According to documentations https://www.sqlite.org/foreignkeys.html they should be enabled manually.

Solution:
To not rely on changes how DBMS handles that now and in the future, developer not can enable / disable foreign keys in database connection explicitly. That now would be possible for all 4 types of database.

Copy link
Member

@josephmancuso josephmancuso left a comment

Choose a reason for hiding this comment

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

LGTM

@josephmancuso josephmancuso merged commit 0524421 into MasoniteFramework:2.0 Jun 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants