Mysql Table
data
----------
id int(11)
keyword varchar(255)
value varchar(255)
score int(11)
Repository Code
public interface DataRepository extends CrudRepository<Data, Long> {
Page<Data> findByKeywordOrderByScoreDesc(String keyword, Pageable pageable);
}
Test Code
Pageable pageable = PageRequest.of(1, 10);
Page<Data> datas = repository.findByKeywordOrderByScoreDesc("apple", pageable);
Logging Property
logging.level.org.hibernate.SQL=DEBUG
logging.level.org.hibernate.type.descriptor.sql.BasicBinder=TRACE
Printed Log
o.h.h.i.QueryTranslatorFactoryInitiator 47 - HHH000397: Using ASTQueryTranslatorFactory
org.hibernate.SQL 92 - select data0_.id as id1_0_, data0_.keyword as keyword2_0_, data0_.value as value3_0_, data0_.score as score4_0_ from data data0_ where data0_.keyword=? order by data0_.score desc limit ?, ?
o.h.type.descriptor.sql.BasicBinder 65 - binding parameter [1] as [VARCHAR] - [apple]
org.hibernate.SQL 92 - select count(data0_.id) as col_0_0_ from data data0_ where data0_.keyword=?
o.h.type.descriptor.sql.BasicBinder 65 - binding parameter [1] as [VARCHAR] - [apple]
Logs only show data0_.keyword=?
binding value.
I want know limit ?, ?
binding values. Is there proper log settings?