I've got a temp table build up with the following columns... AssignmentSubType AssignmentValue OwnerUsergroupID AssociatedObjectID:
AssignmentSubType
AssignmentValue
OwnerUsergroupID
AssociatedObjectID
The basic gist of what I want to do is to find associatedobjectidsAssociatedObjectID
s that have the same assignmentsubtypeAssignmentSubType
, assignmentvalueAssignmentValue
, and ownerusergroupidOwnerUsergroupID
. This is because there is a ton of sqlSQL down the road that really doesn't need to be run if I've got "duplicates" (same assignmentsubtypeAssignmentSubType
, assignmentvalueAssignmentValue
, ownerusergroupidand OwnerUsergroupID
). Once I've got my list of duplicates I run the next set of sqlSQL stuff on one of the duplicates , when I've got back info from that I join back the rest of the duplicates for the final result set....
inIn this example I just want to do the calculations on associatedobjecid = 5 since 7 and 9 will be the exact same, and then join back in 7 and 9 at the 'end'