If you do it based on time. Make time part of the name, like db-08-07-203014.db (day-month-time). Now you might as well used a random number.