"<-" 属性的问题 #735
Labels
No Label
backport/done
backport/v1
blocked
db
oracle
db
sqlserver
duplicate
feature
cache
frontport/done
frontport/main
invalid
kind
breaking
kind
bug
kind
build
kind
dependencies
kind
docs
kind
driver
kind
enhancement
kind
feature
kind
performance
kind
proposal
kind
question
kind
refactor
kind
testing
need
feedback
need
test
proposal:accepted
RaspBerry Pi
regression
skip-changelog
upstream
wip
wontfix
No Milestone
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: xorm/xorm#735
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
结构体中的一个字段是多表查询时临时存储数据用的,不用直接写入数据库,所以我将它声明为"<-",我的理解是加了这个属性的字段在create/update时不会在sql语句中生成字段信息。
但是实际操作起来发现sql语句中还是有这个字段。
我只能显示地在Omit中加入排除这个字段才行。
是我对这个属性的理解有误还是BUG?
<-属性只是表示这个字段在插入和更新时不会出现,在获取时还是有。
那我理解的是正确的,但是我反馈的图片中可以看到,我是执行的Update操作,然而sql语句中还是出现了。
感觉是因为你用了 AllCols 所以就会出现了