Goyesql
Go + Yesql
**goyesql** is a Go + Yesql The project is written primarily in Go, distributed under the BSD 2-Clause "Simplified" License license, first published in 2015. Key topics include: go, kiss, sql.
Latest release: v1.0.2
November 16, 2023View Changelog →
goyesql
Golang + Yesql
Parse a file and associate SQL queries to a map. Useful for separating SQL from code logic.
Installation
$ go get -u github.com/nleof/goyesql
Usage
Create a file containing your SQL queries
sql-- queries.sql -- name: list SELECT * FROM foo; -- name: get SELECT * FROM foo WHERE bar = $1;
And just call them in your code!
goqueries := goyesql.MustParseFile("queries.sql") // use queries["list"] with sql/database, sqlx ...
Enjoy!
Contributors
Showing top 3 contributors by commit count.
This article is auto-generated from nleof/goyesql via the GitHub API.Last fetched: 6/29/2026
