-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Enable SQLite foreign key on post-connect #2833
Comments
I've an event subscriber to enable that: would you suggest to add an |
@Federkun yup 👍 |
SQLite has a compile-time option to enable foreign_key enforcement by default. https://www.sqlite.org/compile.html#default_foreign_keys The default build of SQLite has foreign_key enforcement turned off by default due to backwards-compatibility concerns. |
Compile-time is not in our ballpark: we are a lib sitting on top of
pre-compiled php binaries.
…On 12 Sep 2017 22:20, "Richard Hipp" ***@***.***> wrote:
SQLite has a compile-time option to enable foreign_key enforcement by
default. https://www.sqlite.org/compile.html#default_foreign_keys
The default build of SQLite has foreign_key enforcement turned off by
default due to backwards-compatibility concerns.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#2833 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAJakA5GiHKvU9pCW5X7ALDDPJMat7uEks5shueAgaJpZM4PK8b7>
.
|
Hello, Have you found any good approach, because foreign keys are missing for ages ? Many thanks all, for all your work |
I did stumble over #5404 and asking myself if FK is now supported via dbal? |
Yes. I think, we can close this issue. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Apparently, SQLite has supported foreign keys for ages! All we need to do is (according to https://sqlite.org/foreignkeys.html) run a statement on post-connect:
Not sure where to do it exactly, but this would be a very welcome addition.
The text was updated successfully, but these errors were encountered: