I notice if I create a model
Car with the string attribute/column
make and do this in the Rails console:
2.1.3 :002 > Car.create make: "Honda" ... 2.1.3 :008 > Car.create ...
I end up with two records, one where make is “Honda” and another where make is null.
Car.where(make: "Honda")returns the first car
Car.where(make: nil)returns the second car
Car.where.not(make: "Honda")returns no records
Car.where.not(make: "Honda") return no records? Logically, I would expect to get all the records that don’t have make set to “Honda”, which would include records with make set to null.
Also, I haven’t quite determined yet exactly what questions are appropriate in this forum versus what are StackOverflow appropriate… if this is not preferred here please delete this and I’ll repost elsewhere.