Announcement

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

    How to debug duplicate checking

    Scenario:
    Entities of a m:n (:= x:y) relation should be related to each other using a relation table (xyRel). I made a generic component which is parameterized amongst others with x,y,and xyRel DS to relate x to y and it works quite well. The duplication checking is also working fine in all cases so far.
    Now, I have another type of x and y with an additional requirement on the relation entities (allow multiple xyRels between x and y that only differ in a third, user defined property). For the time being, a xyRel id is used as primary key (to reduce debugging complexity). Later it is to be replaced by a composed primary key (but that's not part of the problem here).
    Now, if duplicate checking is turned off, relating those entities is no problem (i.e. a xyRel record is created). Else (duplicate checking is turned on), the duplicate check asserts that there already is a matching record in the target grid. Developer Console says
    Code:
    12:12:33.775:TMR9:DEBUG:dragDrop:Found client-side duplicate, adding 'gp352' to exception list.
    where (gp352) is the primary key of the source grid.
    The funny thing is that the target xyRel grid (and the corresponding table) is completly empty.
    I am pretty sure that I made a small mistake somewhere (e.g. wrong key names) but cannot figure out where. Probably the best option would be to check what happens during the duplicate checking and to find out why the duplicate checking complains about a potentially duplicate record when the target grid is empty. But I have no clue how to do that and I am completely relying on the GWT-Black box (basically, I do not know JS). So, is there an appropriate override point for intercepting the event queue and to print out additional information that would help with debugging? Or maybe some additional useful setting in the development console?

    Thanks
    fatzopilot

    SGWT 2.4 (as of 03/08/11), GWT 2.1.1., Firefox 4.0.1
Working...
X