Is it possible for a Grails Domain to have no 'id'?

后端 未结 5 1893
孤城傲影
孤城傲影 2021-02-06 05:32

Is it possible to create a table that has no \'id\'? For example, this is my domain:

class SnbrActVector {

    int nid
    String term
    double weight

    st         


        
5条回答
  •  面向向阳花
    2021-02-06 05:52

    Try using: "id( generator: 'assigned')" instead of "id generator: 'identity'" and see if that removes the autoincrement property from the "id" database column.

提交回复
热议问题