Hello, there,
I have a table tblData which has pharmacy data. The table has
following fields:
ClaimNum, LineNum...
The ClaimNum has claim number which is 12 characters. LineNum is NULL.
The table looks like this
ClaimNum LineNum
abcde1234561
abcde1234561
abcde1234562
abcde1234563
abced1234564
abcde1234564
abcde1234564
abcde1234564
abcde1234564
abcde1234565
The thing is that I have some duplicate ClaimNum, which is
understandable because some claims may have mutiple lines. I would
like to update the [LineNum] to 1 if the ClaimNum is not duplicate, to
2 if it is the second duplicate, to 3 if it is the third duplicate...
So, the combination of ClaimNum and LineNum could serve as Primary
key.
so the table would look like
ClaimNum LineNum
abcde1234561 1
abcde1234561 2
abcde1234562 1
abcde1234563 1
abcde1234564 1
abcde1234564 2
abcde1234564 3
abcde1234564 4
abcde1234564 5
abcde1234565 1
Thanks a lot in advance.
Pablo
I have a table tblData which has pharmacy data. The table has
following fields:
ClaimNum, LineNum...
The ClaimNum has claim number which is 12 characters. LineNum is NULL.
The table looks like this
ClaimNum LineNum
abcde1234561
abcde1234561
abcde1234562
abcde1234563
abced1234564
abcde1234564
abcde1234564
abcde1234564
abcde1234564
abcde1234565
The thing is that I have some duplicate ClaimNum, which is
understandable because some claims may have mutiple lines. I would
like to update the [LineNum] to 1 if the ClaimNum is not duplicate, to
2 if it is the second duplicate, to 3 if it is the third duplicate...
So, the combination of ClaimNum and LineNum could serve as Primary
key.
so the table would look like
ClaimNum LineNum
abcde1234561 1
abcde1234561 2
abcde1234562 1
abcde1234563 1
abcde1234564 1
abcde1234564 2
abcde1234564 3
abcde1234564 4
abcde1234564 5
abcde1234565 1
Thanks a lot in advance.
Pablo
Comment