3 Replies Latest reply on Sep 26, 2006 8:49 AM by azadisaryev

    Looping over method which returns a query

    CF_WebHed
      HI,

      I have a method that returns a query, I pass into this method a ID number, which the query uses in the where clause. Now I have another query which returns a list of ID numbers that I loop through calling the first method and passing in the ID number, for example

      methodA

      loop through methodA results
      call methodB passing in methodA.ID
      get results from methodB
      close loop

      now the problem I'm having is that methodB returns a query and I want to be able to return the results from methodB as one single query structure. I'm not sure how many times I will loop through the results from methodA, it could be twice, it could by ten time. So the results from calling methodB could be very large.
      How can I add the results from methodB into one single query structure?