What's the equivalent of JPA or JDBC for node?

database, driver, node.js

Solution

Not exactly, but the Loopback Framework for Node.js has ORM-like data source connectors that allow you to connect to many data sources through a common syntax. It's a full enterprise-grade framework, so has a lot of other components as well. Other frameworks like Sails.js have similar components.

Sequelize is a great ORM for PostgreSQL, MySQL, SQLite and MSSQL.

TypeORM is also great and supports MySQL, PostgreSQL, MariaDB, SQLite, MS SQL Server, Oracle, SAP Hana, WebSQL databases. Works in NodeJS, Browser, Ionic, Cordova and Electron platforms.

Problem

I'm pretty new to node, and I was wondering if there's any standard, open, API that could abstract me away from all the different database idiosyncrasies. Any link with tutorials or documentation would be pretty much welcome indeed.

Original source