Skip to content

DatePreposition is generating the wrong SQL to find NULL values#14

Open
boblail wants to merge 1 commit intomasterfrom
fix-date-preposition
Open

DatePreposition is generating the wrong SQL to find NULL values#14
boblail wants to merge 1 commit intomasterfrom
fix-date-preposition

Conversation

@boblail
Copy link
Contributor

@boblail boblail commented Feb 9, 2016

I think this is a bug in Arel:

people[:birthday].not_eq(nil) # => "people.birthday IS NOT NULL"
Arel.sql("values.value::date").not_eq(nil) # => "values.value != NULL"

The latter is invalid syntax.

This PR has a failing test, but not a fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant