Hacker GitHub

← All repos

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

Mentions per year 14 mentions · busiest year 2019 (3)
20082026
  1. ▲ 1
    Show HN: Dumb Query Language for Go
    story by tomakado · 2025-03-21 · 0 comments
  2. 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…
  3. …interface than manually hacking together strings as the Golang example others have linked shows: https://github.com/Masterminds/squirrel
  4. 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…
  5. …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
  6. 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…
  7. Does Squirrel cover your needs? https://github.com/Masterminds/squirrel
    comment by reificator · 2019-11-08 · in Go Turns 10
  8. …So again, back to string concatenation to support both or use some library like squirrel[1]. [1] https://github.com/Masterminds/squirrel
  9. …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
  10. …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…
  11. 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
  12. …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...
  13. ▲ 4
    Squirrel – fluent SQL generator for Go
    story by lann · 2014-01-28 · 0 comments
  14. > 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