Conditions on Joined Tables

Hi

I don’t see how to write correctly conditions for the following
query :

association:
client has_many :orders

I would to get in one query :

all clients with NO ORDER + clients with orders where Today IS NOT in
range (order.start_date… order.end_date)

is it possible or should I write 2 queries then join the resulting
arrays ?

thanks

erwin

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs