"deep" search – similar to an SQL "join"

Home Forum SugarCRM CE and SuiteCRM Development Help "deep" search – similar to an SQL "join"

Tagged: 

This topic contains 1 reply, has 2 voices, and was last updated by Andy Andy 4 years, 4 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #187

    Trash
    Participant

    Hi!
    I am trying to create a search field that would check a field in a related object: I have a custom module – “ModA” with a Date field “Mdate”. and my contacts Module has a OneToMany relationship to ModA. how could I create a search that would return all Contacts with a ModA object that has a certain “Mdate” ?

    (or, for example, all clients that recieved a call yesterday)

    thanks 🙂

    #188
    Andy
    Andy
    Keymaster

    How do you envision the results being returned back and displayed? Is this in the global search of within the contacts module?

    You would create a custom controller action that would loop through all the ModA records with the Mdate then get their related contacts and return them.

    http://developer.sugarcrm.com/2012/03/23/howto-using-the-bean-instead-of-sql-all-the-time/

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

Posted in