I have a complex situation. I have a list of related records (see
partial extract below) where I am trying to determine the unique lowest
number for each relation. This number should always be an AB number,
since all the MA numbers will always relate to an AB number. I need the
distinct, lowest values that relate to each other, not necessarily in
the same row.
What I have so far is:
if (test.Field1 < test.Field2,test.Field1,test.Field2)
AS `Unique Incident id`
The problem is that the data is recursive and non-exclusive, by which I
mean that the data will always be in both columns, and it is possible
that more than one relation exists. In the case of more than 1 relation
I still need the just lowest distinct value in the relation, no matter
how many other members of the relation exist.
Can anyone offer any suggestions?
Here is some sample data to chew on.
This e-mail, including any attachments, may be confidential, privileged or otherwise
legally protected. It is intended only for the addressee. If you received this e-mail in
error or from someone who was not authorized to send it to you, do not disseminate, copy
or otherwise use this e-mail or its attachments. Please notify the sender immediately by
reply e-mail and delete the e-mail from your system.