The Oracle view does not have a primary key by default. Therefore, when you use hibernate to generate a java class in reverse direction, a composite primary key is automatically used to generate a class with the class name + ID, which makes it difficult for later development.
The Oracle view does not have a primary key by default. Therefore, when you use hibernate to generate a java class in reverse direction, a composite primary key is automatically used to generate a class with the class name + ID, which makes it difficult for later development.
The Oracle view does not have a primary key by default. Therefore, when you use hibernate to generate a java class in reverse direction, a composite primary key is automatically used to generate a class name + ID, which makes it difficult for later development.
Therefore, adding a primary key to the oracle view is an option to solve the problem.
The SQL statement is as follows:
Create or replace view v_xxx (id, text, CONSTAIN id_pk primary key (id) rely disable novalidate)
SELELCT xxx. code id, xxx. name text
FROM xxx
WHERE something;