The fantastic ORM library for Golang, aims to be developer friendly
Go to file
Jinzhu 0491675ae8 Break find code into sql.go file 2013-10-26 11:59:58 +08:00
Guardfile Initialize the tests 2013-10-25 22:31:56 +08:00
README.md Initialize with README 2013-10-25 16:24:32 +08:00
main.go Add more dummy code for orm.go 2013-10-26 07:14:57 +08:00
orm.go Break find code into sql.go file 2013-10-26 11:59:58 +08:00
orm_test.go yay, find from db works 2013-10-26 11:48:07 +08:00
sql.go Break find code into sql.go file 2013-10-26 11:59:58 +08:00
utils.go yay, find from db works 2013-10-26 11:48:07 +08:00

README.md

GORM

Yet Another ORM library for Go, hope sucks less. (created for internal usage, API is breakable)

TODO

Where("id =/>/</<> ?", string or int64).First(&user) (error) Where("id in ?", map[]interface{}).First(&user) (error) Where("id in ?", map[]interface{}).Find(&users) (error) Where(map[string]string{"id": "12", "name": "jinzhu"}).Find(&users) (error) Order("").Limit(11).Or("").Count().Select("").Not("").Offset(11)

First(&user, primary_key) (error)

Save(&user) Save(&users) Delete(&user) Delete(&users)

Before/After Save/Update/Create/Delete Where("id in ?", map[]interface{}).FindOrInitialize(&users) (error) Where("id in ?", map[]interface{}).FindOrCreate(&users) (error)

Sql("ssssss", &users)

SQL log Auto Migration Index, Unique