As far as I remember, ecto does translate this into proper comparison on the SQL level, and the DateDtime struct isn’t actually involved in the comparison.
The linked article is 4 years old and probably refers to a version of elixir that is not only deprecated but literally dead.
At the time the article got released, ecto 1.0.7 was current. Today we are at 3.2.2.
The Ecto.DateTime module has been deprecated in 2.2.4.
So I won’t say that article is pointless, I’d just say its not applicable anymore today, but it might have had its worth back the day it has been published.