Solved Serial number in Alphabets in MS Reports

daud

New member
Local time
Today, 09:55
Joined
May 28, 2009
Messages
14
I want to assign serial number to each record via property>data>=1 overall. Its OK and serial 1, 2, 3 etc. However, I want to serial number alphabeticlly i.e a b c d and so on. I did this once in past using CHR(97), ASCII 97 represents a 98 represents b and so on. Unfortunately I could not do it now. If someone can help.
Regards and best wishes
 
Perhaps an example would clarify your intent.
 
use one of the common methods to add numbers, then add 97 or 96 depending on whether the numbers start from 0 or 1

not clear from your post whether you are trying to do this in a query to update a table or using a rownumber in a report.

If a report, see this link for generating a rownumber

 
If you don't ever have more than 26 items, then you can just use an array to convert a sequence number to a letter. If you have more than 26, then you need to use base 26 arithmetic. It's just like working with hours:minutes:seconds which is base 60. ALSO, to make a multi-column alpha "number" sort correctly, it must be right-justified and space filled.
 

Users who are viewing this thread

Back
Top Bottom