Masterminds/squirrel
View on GitHub ↗ ★ 7,987 Go
Fluent SQL generation for golang
14 mentions on Hacker News by 13 people: 2 stories, 12 comments · first 2014-01-26 · latest 2025-03-21
20082026
-
https://GitHub.com/masterminds/squirrel sounds like what you want, in Go at least. They bill it as a SQL query builder instead of an ORM. It lets you build SQL queries using code and just returns the built SQL query as a string, the list…
comment by everforward · 2024-02-01 · in ORMs are nice but they are the wrong abstraction -
…interface than manually hacking together strings as the Golang example others have linked shows: https://github.com/Masterminds/squirrel
comment by BoorishBears · 2022-12-29 · in Ask HN: What's a build vs. buy decision that you got wrong? -
golang https://github.com/Masterminds/squirrel Constructing sql by concat strings has a few issues, its repetitive and hard to assemble certain queries conditionally, and at least in golang its easy to write code vulnerable to sql…
comment by dosethree · 2022-12-29 · in Ask HN: What's a build vs. buy decision that you got wrong? -
…package before Ent was Squirrel [1] but I definitely plan to use Ent for future projects. [1] https://github.com/Masterminds/squirrel
comment by syvolt · 2022-10-31 · in Ent: An Entity Framework for Go -
We just use something like github.com/Masterminds/squirrel in combination with something like github.com/fatih/structs (it's archived, but it's easy code to write) to help with sql query generation, and use github.com/jmoiron/sqlx for…
comment by ramenmeal · 2021-09-08 · in How We Went All In on sqlc/pgx for Postgres and Go -
Does Squirrel cover your needs? https://github.com/Masterminds/squirrel
comment by reificator · 2019-11-08 · in Go Turns 10 -
…So again, back to string concatenation to support both or use some library like squirrel[1]. [1] https://github.com/Masterminds/squirrel
comment by matwood · 2019-11-08 · in Security assessment techniques for Go projects -
…I haven't used it, it does look rather interesting. [1] - https://github.com/jmoiron/sqlx [2] - https://github.com/masterminds/squirrel
comment by bkq · 2019-05-07 · in To ORM or Not to ORM -
…library is too basic for professional use https://github.com/CloudyKit/jet . I don't use ORM, I use https://github.com/Masterminds/squirrel for query building and https://github.com/jmoiron/sqlx which helps deals with row<=>struct…
comment by nostalgeek · 2018-07-14 · in Ask HN: What is the current state of web frameworks in Golang? -
I've used https://github.com/jinzhu/gorm with Go, and it's ok. Sometimes I just use https://github.com/Masterminds/squirrel or https://github.com/elgris/sqrl with database/sql or https://github.com/jmoiron/sqlx
comment by ptman · 2017-06-20 · in Macaron: a high productive and modular web framework in Go -
…them as "evil" or believing that everyone should repeat data access code in all projects. [1] http://github.com/lann/squirrel [2] http://en.wikipedia.org/wiki/Object-relational_impedance_mis...
comment by jmoiron · 2015-05-08 · in Go-bootstrap: Generates a lean and mean Go web project -
> SQL I'm working on an arel-esque fluent SQL generator now: https://github.com/lann/squirrel I'll release it once I'm a little more confident in the interface. Currently you can do things like this: rows, err := Select("col").…
comment by lann · 2014-01-26 · in A RESTful Micro-Framework in Go