Skip to content

Conversation

@demon101
Copy link
Contributor

@CLAassistant
Copy link

CLAassistant commented Feb 14, 2019

CLA assistant check
All committers have signed the CLA.

@graemerocher
Copy link
Contributor

Note that this fixed actually doesn't work downstream with Hibernate. I have disabled the tests that fail for the new test that was introduced until that can be investigated grails/grails-data-hibernate5@671413c

@graemerocher
Copy link
Contributor

The test also fails in GORM for Neo4j

@demon101
Copy link
Contributor Author

@graemerocher where I can find tests logs? Is it problem of test or code?

@graemerocher
Copy link
Contributor

likely a problem with how the query is translated into the target query for each underlying implementation. The builds are run via Travis, but the logs won't tell you much other than NullValueEqualSpec you would need to run the tests for the underlying implementations (gorm-hibernate5 and gorm-neo4j)

@demon101
Copy link
Contributor Author

@graemerocher strange, I have tested on app with 6.1 snapshot version (hibernate 5), everything works as expected, also NotEqual. Looks like problem in tests

@zyro23
Copy link
Contributor

zyro23 commented May 14, 2019

i think the problem is again that NULL in sql is never equals meaning that:

TestEntity.countByAgeNotEqual(11) == 2

fails because WHERE age <> 11 does not match the rows with age = NULL.

to make the test pass, the semantics/implementation of the NotEqual dynamic finder would have to be changed to match NotEqualOrIsNull for non-null values, i guess?
that of course may break existing application code, but this pull request already translates Equal(null) to IsNull (for all datastores) which both have a different meaning and different expected results in sql, too.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants