What Franco Bruno Borghesi says is a goos idea.
You can prevent the user from duplicate submits.
If you want to keep some fields unique in a table, please
rely on the DBMS. PostgreSQL support primary key,
foreign key, unique index and other facilities to keep
data integrity. And I think it can do things better most
of the time.