4 ms·
database/sql provides a generic interface for SQL which drivers use to build their libraries. You can switch from one postgres driver like pq to pgx easily beca
by impulser_ 3y ago
database/sql provides a generic interface for SQL which drivers use to build their libraries. You can switch from one postgres driver like pq to pgx easily because they both support database/sql.
- ibraheemdev 3y agoExcept pgx recommends using their native interface, not database/sql, for performance and extra features [0], so it's not that simple in practice. [0]: https://github.com/jackc/pgx#choosing-between-the-pgx-and-databasesql-interfaces https://github.com/jackc/pgx#choosing-between-the-pgx-and-da...