Thanks for the reply. On Thursday, May 12, 2016 at 10:15:45 PM UTC+5:30, Jeremy Evans wrote: > > On Thursday, May 12, 2016 at 9:26:27 AM UTC-7, Satyanarayana Gandham wrote: >> >> Hi, >> >> Please refer to the following link: >> http://stackoverflow.com/questions/11022025/sequel-model-over-two-joined-tables >> >> <http://www.google.com/url?q=http%3A%2F%2Fstackoverflow.com%2Fquestions%2F11022025%2Fsequel-model-over-two-joined-tables&sa=D&sntz=1&usg=AFQjCNFbFA_PjriH3kv4RUUrNoFcCcSZiA> >> >> I am trying to tackle a similar problem. The main issue I am facing is >> the User dataset will look for values on the auth_users table only. I >> cannot filter the results by phone field using the following: >> "User.dataset.where(phone: "98xxxxxxx69")". Is there a way, I can filter >> the results by phone which is in a different table. >> > > If the model's dataset is for one table, and the phone column is in a > different table, you either need to join to the table containing the phone > column, or use a subquery. > > 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 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.
