使用下面的代码来保存float的值
domainInstance.standardScore = params["standardScore"] as float
在这种情况下,我的输入为17.9,在db2数据库中保存为17.899999618530273,但我想保存为17.9本身,让我知道如何做到这一点
floating-point groovy
floating-point ×1
groovy ×1