Thank you, Jeremy! It did worked.

One last question. About migrations. I have a few foreign keys already 
declared and they are set to "on delete SET NULL". I would like to change 
them to "on delete CASCADE". I know there was a way of doing this but 
alter_table seems not mentioned about this. How can I change cascade styule 
for an existing foreign key using migrations?

Thanks,
Gencer.

On Wednesday, June 25, 2014 at 1:54:21 PM UTC+3, Simon Dahlbacka wrote:
>
> Hi,
>
> I've tried to read the docs but haven't been able to figure out how to get 
> the two following where clauses ORed together
>
> .where(:OACUOR => request[:customersOrderNumber])
> .where(db[:OOLINE].where(
>    :OBCONO => request[:company],
>    :OBORNO => :OAORNO,
>    :OBCUOR => request[:customersOrderNumber]).exists))
>
> i.e.
>
> the resulting SQL should be
>
> select * from foo WHERE (:OACUOR='foo') OR (EXISTS(SELECT * FROM OOLINE 
> WHERE OBCONO=100 AND OBORNO=OAORNO AND OBCUOR='foo'))
>
>
> How to achieve that? (I'm using the jdbc/as400 adapter if that matters)
>
>
> And thanks for sequel btw!
>
> regards,
> Simon
>

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to