For example, I have a table like this
@Entity
@Table(name="EmpEnverPrac")
@Audited
public class EmpEnverPractice {
@Id
@Column(name="ID")
@GeneratedValue(strategy = GenerationType.AUTO)
private Integer id;
@Column(name="NAME")
private String name;
@Column(name="password")
@NotAudited
private String password;
// getter and setters
}
Now I want to use the audit table I generated I added some extra columns, but I don’t want to include them in my entity. I can’t find any solution that meets this requirement. Please tell me the required configuration. Thanks in advance
Is it possible to add other columns in the audit table?
For example, I have a table like this
@Entity
@Table(name="EmpEnverPrac")
@Audited
public class EmpEnverPractice {
@Id
@Column(name="ID")
@GeneratedValue(strategy = GenerationType.AUTO)
private Integer id;
@Column(name="NAME")
private String name;
@Column(name="password")
@NotAudited
private String password;
// getter and setters
}
Now I want to use the audit table I generated I added some extra columns in my entity, but I don’t want to include them in my entity. I can’t find any solution that meets this requirement. Please tell me the configuration required. Thanks in advance
I found a solution because I can add an extra column (the default name given by hibernate) to the REVINFO table. This table stores a timestamp for each transaction in the application Id so that I can get information about any transaction. Here are references http://docs.jboss.org/envers/docs/#revisionlog