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 support for views #29

Open
ad-si opened this issue Oct 5, 2019 · 3 comments
Open

Add support for views #29

ad-si opened this issue Oct 5, 2019 · 3 comments

Comments

@ad-si
Copy link

ad-si commented Oct 5, 2019

Is there a fundamental problem preventing this?

@bradleyboy
Copy link
Owner

bradleyboy commented Oct 7, 2019

@ad-si I'm not that familiar with views, so I guess that's the fundamental problem 😄

My 5 minute read seems to show that Sequelize (which tuql uses under the hood) doesn't support SQLite views, so that may be a blocker.

@ad-si
Copy link
Author

ad-si commented Oct 8, 2019

I'm not that familiar with views

Well, views are just queries which yield a new (read only) table. Reading from a table or a view works exactly in the same way, so it's really straight forward.

My 5 minute read seems to show that Sequelize (which tuql uses under the hood) doesn't support SQLite views, so that may be a blocker.

What the 😳. I guess that's why I never use ORMs. Completely useless abstraction. Since this project is explicitly for SQLite databases, maybe you shouldn't use it either? I feel like having direct access to all SQLite features would be handy…

@bradleyboy
Copy link
Owner

Completely useless abstraction. Since this project is explicitly for SQLite databases, maybe you shouldn't use it either?

Not completely useless, it allowed for this library to be created quickly without writing a bunch of SQL plumbing myself 🤷‍♂

Regardless, views are not something I have needed for this, happy to look at a PR that brings support for them though.

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

No branches or pull requests

2 participants