ActiveRecord: milliseconds aren't taken into account when using a where clause

后端 未结 2 1474
醉话见心
醉话见心 2021-01-05 07:18

I\'m working on a project with a rails api and an iOS client, using the updated_at field as the reference to detect modifications on the server that happened after the last

2条回答
  •  执笔经年
    2021-01-05 08:10

    If you're using the ISO8601 standard you can use .iso8601(10). Don't know why but it rounds to seconds by default.

提交回复
热议问题