SELECT Alias.PartID, Alias.AliasID, Alias.Type, Alias.Comment, 1+DCount("PartID","Alias","[PartID]='" & [PartID] & "' And [IdNum]<" & [IdNum]) AS PC INTO Alias_T
FROM Alias;
Have a Part ID, and alias for items in stock. The Part ID is repeating with multiple aliases.
I want each alias to be numbered for the Part ID, like 1, 2, 3 then new Part Id starts, so the numbers start over.
The query works, but takes about 30 seconds to execute.
I am running against a SQL Server table if that makes any difference. IDnum is an autonumber identity field.
Thanks,
ChaZ
FROM Alias;
Have a Part ID, and alias for items in stock. The Part ID is repeating with multiple aliases.
I want each alias to be numbered for the Part ID, like 1, 2, 3 then new Part Id starts, so the numbers start over.
The query works, but takes about 30 seconds to execute.
I am running against a SQL Server table if that makes any difference. IDnum is an autonumber identity field.
Thanks,
ChaZ