Join two table when both has Composite Primary Key

Thanks Vlad,

Application gets many record from database to generate CSV file, that’s why i need big fetch size to limit request to Database via the network, to get records faster. For UI fetch size is set to 50.

The reason that the HQL was working slowly was the hibernate logging which I had turned on to TRACE, and the most time was wasted to create 500 MB hibernate log file :slight_smile:
i just changed <property name="hibernate.generate_statistics">true</property> to false
and change TRACE to INFO in to log4j2.properties file, and know everything works perfectly.