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

SQLite support for database #961

Closed
sammcj opened this issue Feb 1, 2023 · 2 comments · Fixed by #2364
Closed

SQLite support for database #961

sammcj opened this issue Feb 1, 2023 · 2 comments · Fixed by #2364
Labels
feature User-facing features and product enhancements

Comments

@sammcj
Copy link
Contributor

sammcj commented Feb 1, 2023

It would be great if there was an option to just use SQLite instead of running a full database server.

While I love PostgreSQL I think SQLite is more than performant enough, it's very lightweight and portable.

I see SQLite is already mentioned in this file - is there anything stopping someone from using it instead?

@Floppy
Copy link
Collaborator

Floppy commented Feb 2, 2023

I've had the same request for MySQL in #665, and I think that given Rails gets everything (including the adapter) from DATABASE_URL, there's a chance it might Just Work if you try a database url like sqlite3:path/to/some/permanent/storage/database.sqlite. I've not tested it, but if you fancy having a go, the sqlite dependency should already be installed, so you never know. Worth a try!

I'll take a look as well when I can, but I don't know when that's likely to be.

@Floppy Floppy added this to the v1.0.0 milestone Feb 5, 2023
@Floppy Floppy added the feature User-facing features and product enhancements label Feb 5, 2023
@ksuquix
Copy link
Collaborator

ksuquix commented Feb 22, 2023

The test harnesses use sqlite, so I see no reason for it to not work.

One warning though, I made one change in the "combined view" that initially worked with sqlite testing, but I had to tweak it to work with postgres because of restrictions postgres placed on joining stuff with .or() (you can see it in models_controller.rb).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature User-facing features and product enhancements
Projects
Archived in project
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants