Hi here,
When I turned on the proper hibernate logging, I can see SQL statements and binding values. When I do a simple JPA/QL SELECT, Hibernates auto add a LIMIT ? to the SQL query, and binding for that value is not show in log. Does anyone know why that is?
Example of QL for "select e from Employee e where e.empNo = :empNo" where empNo=500002
Code:
13:21:19.896 [main] DEBUG org.hibernate.SQL -
select
employee0_.emp_no as emp1_0_,
employee0_.birth_date as birth2_0_,
employee0_.first_name as first3_0_,
employee0_.gender as gender0_,
employee0_.hire_date as hire5_0_,
employee0_.last_name as last6_0_
from
employees employee0_
where
employee0_.emp_no=? limit ?
13:21:19.896 [main] TRACE org.hibernate.type.IntegerType - binding '500002' to parameter: 1
13:21:19.896 [main] TRACE org.hibernate.type.IntegerType - returning '500002' as column: emp1_0_
Thanks,
-- Zemian