Java – How to Generate Unique Serial Number in Database using Java