Counter of the entries on the export



I try to customize my export layout. I would like to have at some point a counter per entry type, in a dblp like fashion. For example, I would like something like [J1] for the first journal or [C4] for the fourth conference.
With different layouts, I can see how to have the J or the C, but I cannot find anything to count the entries.

Any clue?