Categorygithub.com/nbs-go/nsql
repositorypackage
0.18.0
Repository: https://github.com/nbs-go/nsql.git
Documentation: pkg.go.dev

# Packages

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# README

nsql

Go Report Card GitHub license codecov

SQL Utility for Golang. Compatible with jmoiron/sqlx. Features:

  • Query Builder (PostgreSQL / MySQL)

Installing

WARNING

API is not yet stable and we might introduce breaking changes until we reached version v1.0.0. See Breaking Changes section for deprecation notes.

go get -u github.com/nbs-go/nsql

Usage

TODO

Breaking Changes

v0.13.0

  • From() and Join() option setter option.As() is deprecated. Use schema.New() option setter schema.As() instead.
    // <= v0.12.0
    person := schema.New(schema.FromModelRef(Person{}))
    query.Select(query.Column("*")).
        From(person, option.As("p")) // <- Set table alias with option.As()
    
    // >= v0.13.0
    person := schema.New(schema.FromModelRef(Person{}), schema.As("p")) // <- Set table alias with schema.As()
    query.Select(query.Column("*")).From(person)
    

Contributors

contributors