Open zhenhua1 opened 11 months ago
Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑🤝🧑👫🧑🏿🤝🧑🏻👩🏾🤝👨🏿👬🏿
goctl 1.6.1 code reports this error, please give me some guidance.
First of all, to be clear this is not a goctl problem, this is a usage problem, please post your structure, I suspect that you are querying a partial field, if it is a partial field please use the method QueryRowsPartial
or QueryRowsPartialCtx
to replace it.
Hi, @zhenhua1
Please send you SysUser
structure example.
作为出参的QueryRowsNoCacheCtx(ctx, &userList, sql2)
函数的第二个实参从命名userList
来看可能是[]User
之类的类型,把sql里的count(*)
改成*
应该就可以了。
Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑🤝🧑👫🧑🏿🤝🧑🏻👩🏾🤝👨🏿👬🏿
The second actual parameter of the
QueryRowsNoCacheCtx(ctx, &userList, sql2)
function as an output parameter may be a type like[]User
from the nameuserList
. Changecount(*)
in sql Changing it to*
should be enough.
goctl 1.6.1代码报这个错误给指导一下