3 ms·
Doesn't almost every language have some kind of abstraction layer that allows this? JDBC/ODBC/DB-API/Sequelize ORM (ignoring the ORM part). This used to be on
by nl 4y ago
Doesn't almost every language have some kind of abstraction layer that allows this?
JDBC/ODBC/DB-API/Sequelize ORM (ignoring the ORM part).
This used to be one of the major use cases for SQLite - running automated tests and being able to throw away the database file (or manage it at different points in the tests).
- hot_gril 4y agoYeah, but the abstraction layers get in the way if/when I need to optimize queries or use special features, plus it's easier to just write SQL. I'd rather target a specific DBMS and rewrite my queries if I ever change it. > ignoring the ORM part As it should be :)
- nl 4y agoNo, all (?) these things let you pass raw SQL straight to the database. In the case of JDBC and ODBC (and I think DB-API) thats all they do.
- hot_gril 4y agoBut raw SQL made for Postgres doesn't necessarily work for SQLite and vice versa. That's what I mean by the SQL standard being thrown out the window. You might be able to write SQL that works in both if you're careful and avoid a lot of features.
- deredede 4y agoODBC doesn't help you if you use any sort of pgsql-specific extension, however.