Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    multiple queries on the same DS

    If I have multiple ResultSets using the same DataSource, can I run multiple data queries (with different criteria) on the same DS simultaneously, or do I have to wait for the first to finish before starting the second?

    (I am manually starting the queries in this case, and users of the data are custom widgets, not DataBound components.)

    #2
    Yes, concurrent queries are allowed.

    Comment


      #3
      But I do need multiple ResultSets for this, right?

      Comment


        #4
        Yes. Or multiple direct calls to DataSource.fetchData() if you don't necessarily need a ResultSet managing the retrieved data.

        Or, a clientOnly DataSource created from the complete dataset you want to work with (if it's small enough) with ResultSets or calls to DataSource.fetchData() on this DataSource, which will happen entirely within the browser and support concurrency as well.

        Comment


          #5
          Thank you for summing up the possibilities.

          In all these cases, what do I have to properly identify (separate) the resulting callback calls? If I have a DataArrivedHandler on the DS, it would fire for all incoming result, so instead of it, I should relay on the callbacks passed directly to the fetch operation, right?

          Comment


            #6
            ResultSet's DataArrived notifications are specific to that ResultSet and will not fire for data arriving in another ResultSet.

            Comment


              #7
              Originally posted by Isomorphic
              ResultSet's DataArrived notifications are specific to that ResultSet and will not fire for data arriving in another ResultSet.
              ...except when I write something to the DS, because then they do fire, right? (Assuming that the set criteria does not hide the change.)

              Comment


                #8
                Yes, if new data is added to that ResultSet's cache, dataArrived can fire.

                Comment


                  #9
                  Originally posted by Isomorphic
                  Yes, if new data is added to that ResultSet's cache, dataArrived can fire.
                  Can fire or will fire?

                  Comment

                  Working...
                  X