Auto-increment is usually implemented at the database layer.
For example, if we have a table in MySQL and it is define as:
table users {
id int(13) not null auto_increment,
name varchar( 45 ) not null default '',
email varchar( 55 ) not null default '',
website varchar( 100 ) not null default '',
primary key( id )
}
As you can see from the above definition, the "id" should be automatically incremented by the database.
The above statement can be executed the same way outside, or inside a JSP page.
If you are not sure about
JDBC and how it works, here is a good tutorial that demonstrates
JDBC connections, data manipulations etc.
Greetings
Marcus