Merged
Conversation
Much like the `mysql` driver's `DriverName`, this allows you to specify a custom driver for SQLite. This is important when creating custom functions, for example.
samuelncui
pushed a commit
to samuelncui/gorm-sqlite
that referenced
this pull request
Oct 4, 2023
…hub.com/glebarez/go-sqlite-1.14.8 Bump github.com/glebarez/go-sqlite from 1.14.7 to 1.14.8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What did this pull request do?
Much like the
mysqldriver'sDriverName, this allows you to specify a custom driver for SQLite. This is important when creating custom functions, for example.I also added unit tests to cover these changes.
User Case Description
I frequently use SQLite in-memory databases for unit tests for my projects that use MySQL and Postgres in production. Part of doing that is creating a custom SQLite driver that has some custom functions for parity with MySQL and Postgres (for example,
CONCATorNOW).Because Gorm v2 does not directly specify the driver on the
Openfunction anymore, this "driver" will need to be able to support it. Themysqldriver already does this, so this just brings this driver up to par with that one.