Documentation
¶
Overview ¶
Package my adapts database/sql and go-sql-driver to the adapter.Tx interface, translating PostgreSQL-flavoured SQL on the way through (§4.3).
Three translations happen here, all of them mechanical:
- $N placeholders become ?, with the arguments permuted to match.
- "double-quoted" identifiers become `backticked` ones.
- Fixed-size byte arrays (UUIDs, commit digests) become []byte on the way in and are copied back on the way out.
The third exists because pgx maps Go's [16]byte to uuid natively and database/sql does not: uuid.UUID's own Value() renders the 36-character text form, which would silently write text into a BINARY(16) column. Converting here keeps that difference out of every call site.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.