值类型的对象在SQLITE中会报错 返回
SqlSugar
253
悬赏:0 飞吻
版本 NET 8.0
数据库:SQLITE
接口返回错误:
{ "statusCode": 500, "errorCode": 500, "error": "Object of type 'System.Int64' cannot be converted to type 'System.Int32'.", "data": null, "timestamp": 1780474788677 }
实体类:
[SugarColumn(IsOwnsOne = true)]
public ImageNoVO ImageNoVO { get; set; }
值对象:
数据库表:
提示:如果把这个“
[SugarColumn(IsOwnsOne = true)]
public ImageNoVO ImageNoVO { get; set; }” 注释,则接口返回没有报错。
或者把 值对象 int 修改 long,则接口返回成功。
或者把 三个参数放在 “T_ImageInfo” 实体中,并注释 “ImageNoVO ImageNoVO”,则接口返回成功。