Hey,
I am trying to convert a simple POJO into a Record by using the JPA @Column
annotation, however JOOQ doesn't take the values.
Here is my sql table:
create table security_roles (
id bigint not null auto_increment,
role_name varchar(255));
And here is my class:
public class SecurityRole implements Role {
private Long id;
private String roleName;
public SecurityRole() {
}
@ConstructorProperties({ "id", "role_name" })
public SecurityRole(Long id, String roleName) {
this.id = id;
this.roleName = roleName;
}
public SecurityRolesRecord getAttachedRecord() {
return UserHelper.dsl().newRecord(Tables.SECURITY_ROLES, this);
}
@Override
@Column(name="role_name")
public String getName() {
return this.roleName;
}
public void setName(String roleName) {
this.roleName = roleName;
}
@Column(name="id")
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
}
The resulting Record shows NULL for both values although the roleName is
set.
Any ideas what I did wrong here?
--
You received this message because you are subscribed to the Google Groups "jOOQ
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.