Searching Questions/Feedback

Viewing 4 reply threads
  • Author
    Posts
  • October 26, 2019 at 4:34 PM #37422

    Rocky Machado
    Participant

    Hello – I wanted to get some feedback on the best method to search and get records based on a search via code. Do I use the getRecords() method and iterate through the records I want to find. My concern with this approach is I will have over 10K records. Also, the search varies. Basically, I’m in one form looking at data and based on some criteria. I will search the record in another table and update the values. SO, I was hoping I could search the form and get the records I need.

    thank you in advance,
    rocky

    October 26, 2019 at 10:37 PM #37430

    Brendan
    Keymaster

    I would recommend using a Saved Search with your criteria already specified. Then get the search and then call getRecords() on it. That way the database does the hard work of searching and you just have to iterate over the results.

    October 27, 2019 at 6:45 PM #37463

    Rocky Machado
    Participant

    Yeah! I saw that in the API. Is it possible to pass parameters values to the saved search? For example, let’s say I have a save search with three search filters, one of the filters I may want to change the value based on data I am using. Hope this makes sense.

    October 28, 2019 at 2:32 AM #37470

    Brendan
    Keymaster

    Makes sense, but it’s not possible at the moment. Saved Search rules are statically defined.

    October 28, 2019 at 6:08 AM #37472

    Rocky Machado
    Participant

    Thanks Brendan, I’ll norrow my search and handle the rest through code.

Viewing 4 reply threads

You must be logged in to reply to this topic.