Hacker News new | ask | show | jobs
ModelQ is a code generator for creating Golang codes to access RDBMS (github.com)
29 points by mijia 4207 days ago
4 comments

I experimented with a similar idea a couple of years ago for pre-generating structs from postgres[1]

Abandoned it pretty quickly though as I didn't find it idiomatic enough, and found the extra compile step rather annoying.

[1] https://bitbucket.org/pkg/pqm

I think you should decide if you're aiming for a micro-ORM or a full ORM and explain that in the readme. A full ORM will probably need a lot of features and take a lot of time to develop and stabilize. You can also look at Jooq (not open source) and see if that is what you want to develop.
I don't want the full ORM, especially don't want to mess around the relation parts. Just want a simple "ORM" tool generating model codes to access the database without the go reflection and taking advantage of the Go compiler.

Thank you very much for the advice though, :)

This line of django-esque query system seems like it could mature into a useful ORM and find it's place in Go Land. There is still quite a ways to go, though.
a.k.a. 'ORM'.