Hey Jeremy, I'm only asking because Sequel is so amazing and I figure I probably missed something somewhere.
It's not a big deal, I just wrote the joins using join_table and it's working well, just bummer can't reuse the associations I already made. Anyways, thanks for the quick response. I'm just glad that all the work I did in the last 2 hours wasn't for nothing because of some simple solution I overlooked. :) Thanks for continuing to support and develop Sequel all these years. Aryk On Wednesday, May 27, 2020 at 5:11:06 PM UTC+3, Jeremy Evans wrote: > > On Wednesday, May 27, 2020 at 3:46:15 AM UTC-7, Aryk Grosz wrote: >> >> I'm trying to chain association joins from table to table. >> >> lets say: >> >> class School < Sequel::Model >> one_to_many :classes, class: "Klass" >> end >> >> class Klass < Sequel::Model >> one_to_many :students >> end >> >> class Student < Sequel::Model >> end >> >> So I know I can do: >> >> School.association_join(:classes) >> >> and I know I can do >> >> School. association_join(classes: :students) >> >> and I know I can do >> >> Klass.association_left_join(:students) >> >> but can I do something "like" >> >> School.association_join(:classes).association_left_join(:students) >> >> Basically I want to use different join types in the nested association >> hashes. >> >> I looked in the advanced associations and looked through the code, but >> could not find how to accomplish this short of just using #join and >> #left_join and not leveraging the associations I already created. >> > > I'm not sure what you want is currently possible, but I'll look into > making it possible. > > Thanks, > Jeremy > -- 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 view this discussion on the web visit https://groups.google.com/d/msgid/sequel-talk/485fae46-98dd-4c9a-9ba4-e8067f6abb33%40googlegroups.com.
