Closed amitsuryavanshi closed 5 years ago
@cheerfulstoic could you have a look at this if you find some time? I remember you talking several times in the past about OR
and the difficulties with it. Is this implementation too simplistic? Or what were your hesitations in implementing it the way it is in this PR? Since this expands the DSL I want to be cautious not to introduce something that will be hard to take away once out there.
Hrmm, this is probably fine given that there is a where_not
method. I think that ActiveRecord uses where.not
and where().or.where()
, so I think the only complain that I would have is with ActiveRecord compatibility
Closing the as this does not sound like a viable option.
Fixes #
This pull introduces:
.where_or
method toNeo4j::Core::Query
eg.
Neo4j::Core::Query.new.where_or(q: {age: 30, name: 'Chunky'})
would generate cypher like
WHERE (q.age = {q_age} OR q.name = {q_name})
Pings: @klobuczek