spring data jpa 自定义sql 左链接查询

@Query(value = "select u.* from appuser_te u LEFT JOIN app_user_history his on his.user_id=u.id where his.apple_app_id=:appleAppId limit 1,3",nativeQuery = true)
List<AppUser> findByFlushId(@Param(value="appleAppId") Integer appleAppId);

 

posted on 2017-06-04 09:03  蝌蚪的精神  阅读(6113)  评论(0编辑  收藏  举报

导航