For anyone with DevX experience with their memory dataset... I have a performance issue, and it's driving me crazy. My table has 6 columns, 5 of which are integers, and the sixth is a string. I filter on two of the integer columns, and and the raw dataset has 276 rows. Calling UpdateFilters takes about 100mS, which seems awfully long for such a simple table. The call is made 276 times, so I get a total of about 27 seconds, just filtering this table. (Although there are 276 rows now, there could be more, if the complete data environment required it. There just happen to be 276 rows in this instance.)

For anyone with DevX experience with their memory dataset...  I have a performance issue, and it's driving me crazy. My table has 6 columns, 5 of which are integers, and the sixth is a string. I filter on two of the integer columns, and and the raw dataset has 276 rows. Calling UpdateFilters takes about 100mS, which seems awfully long for such a simple table. The call is made 276 times, so I get a total of about 27 seconds, just filtering this table. (Although there are 276 rows now, there could be more, if the complete data environment required it. There just happen to be 276 rows in this instance.)

I am considering whether to leave it unfiltered, and search for the record(s) which would satisfy the criteria, or b) perhaps copy the whole mess to an array of records, and implement a search... or c) convert to using TClientDatasets.

I tried adding indexes, and it made no difference. Basically, everything I have tried so far is counterintuitive in its impact.

Comments

  1. On the other hand, as it turns out, SetRange returns a result set not in the original row order. So I will need then to add an index column to enforce the original sequence, and may lose some performance from that.

    ReplyDelete
  2. Bill Meyer I think you can just add the ordering you want to the index you're using with SetRange, and then omit selecting on the last index field.  Thus, the dataset is subset by the fields you do specify in the SetRange, and the result/remainder is then automatically ordered by the other field(s) in the index.

    ReplyDelete
  3. Walter Prins I had some difficulty in that area, and for one dataset, at least, solved it by using a filter, as well. It seems odd that it would not be easily possible to index, for example, three columns, and then set range using only one. It also seems apparent that the column(s) on which you do not wish to set a range should be later in the list of fields.

    ReplyDelete

Post a Comment