i have programe where i use serial number for each document number. now i want to start serial number with one againe in new financial year, but restarting number with one result in duplication of reference number in database. how to get this.

You can create a year table where you can store the year as 2010,2011,2012 and so on and use the id of the year in your transaction table. When year will change u can easily start the serail number again with 1 and it will also not create any duplicacy as serial number will be associated with the year ID.

thanks

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.