Increment Account Numbers

Giganews Newsgroups
Subject: Increment Account Numbers
Posted by:  rickree (rickr…
Date: Tue, 4 Jan 2011


I'm trying to figure out a way to generate account number and
increment them based on dates.  For example:

    A-Account Number                    B-Date
1  P010110-01                        01/01/10
2  P010110-02                        01/01/10
3  P010210-01                        01/02/10
4  P020310-01                        02/03/10
5  P020410-01                        02/04/10
6  P020410-02                        02/04/10
7  P020410-03                        02/04/10

So in column A the account number is generated by the date entered in
column b.
If the date enter is 02/02/10 than the account number automatically
generated should be P020210-01, but if that date already exists than
the account number should increment to -02 and so forth.