Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用以下查询,它显示空结果但记录存在于表中。请让我知道怎么做
select * from wp_rg_lead_detail where lead_id=5047 and field_number=1.6 select * from wp_rg_lead_detail where lead_id=5047 and field_number=1.6
在这两种情况下查询都返回空结果。但数据存在于表中。
field_number 的数据类型是数据库中的浮点数。
将列更改为十进制或数字,它们存储精确的数字数据值。浮点数始终是近似数字(以存储方式)
编辑:试试这样
select * from wp_rg_lead_detail where lead_id=5047 and format(field_number,1)=1.6