-
reference #2663
-
https://momo733.com/2019/06/13/attention-with-gorm/
golang的orm框架比较流行的是gorm和xorm,gorm的封装对比于xorm来说更加完善,使用不当一不小心就能使你的服务性能下降很多,本文主要说些你使用过程中需要注意的地方。 1.指定数据类型大小gorm相当便利,你只需要建立所需要的结构,使用db.CreateTable(mode…
-
i try to insert to mysql but got empty string, and test lot of different tags, but still empty
```
Number string `xorm:"uuid default uuid()" json:"number"`
```
or
```
…
-
I have something like this:
`
type Foo struct {
ID string 'xorm:"uuid pk"'
Col1 string 'xorm:"col1"'
Flag bool 'xorm:"tinyint"'
}
`
when I tried to do a engine.Id("someid").Update(&Foo…
-
Proposal sollution about limit org's repo number.
Add a new identity named as ``main owner`` in a org, which is the creater of org, and can be changed but should be only one in a org, The orgs repo…
-
When field's names contain a underscore between a letter and a number cause "無效的資料行名稱" error,
but it works fine when a underscore between letters
For example:
```
Table Mark
- mark_1 VARCHAR…
-
According to https://github.com/casbin/xorm-adapter/blob/f11f9b23cc3de66ee2c4e3e3670ab85dc96c3b86/adapter.go#L252, it seems it is expected as we called `SavePolicy`
-
When a field has the tag "autoincr", in the insert process Xorm will always try to select the next value for the sequence from a fixed sequence, named:
https://github.com/go-xorm/xorm/blob/master/s…
rofly updated
5 years ago
-
I was interested how other go projects handle their db stuff and took a look on gitea. They seem to use https://gitea.com/xorm/xorm which abstracts the specific db as well as table generation from str…
-
### Feature Description
As we have a globally `db.SearchOrderBy` for sorting, in some places we still using `xorm.Session.Asc(col_name)` and `xorm.Session.Desc(col_name)` which may make mistakes like…