How to apply auto increment of customize ID in Grails 3 like-
STD_ID
-----------
REG-17-0001
REG-17-0002
REG-17-0003
How to apply auto increment of customize ID in Grails 3 like-
STD_ID
-----------
REG-17-0001
REG-17-0002
REG-17-0003
You can customize the generator
in your mapping
closure:
static mapping = {
id generator: 'hilo'...
}
See the documentation1, documentation2.