@Query(value="select id,intro,name,watch,banner_img_url,apply_status from game_project_tb where apply_status = 1 and id >= (select floor(RAND()*(select MAX(id) from game_project_tb))) order by id limit 10",nativeQuery=true)
@Query(value="select id,intro,name,watch,banner_img_url,apply_status,bot_account,user_nickname from game_project_tb where apply_status = 1 and id >= (select floor(RAND()*(select MAX(id) from game_project_tb))) order by id limit 10",nativeQuery=true)
List<GameProjectTb>recommendList();
@Query(value="select p.id,p.intro,p.name,p.watch,p.banner_img_url,p.apply_status from game_project_tb as p,game_project_label_tb as l where l.name= :category and p.id = l.project_id and p.apply_status=1",nativeQuery=true)
@Query(value="select p.id,p.intro,p.name,p.watch,p.banner_img_url,p.apply_status,p.bot_account,p.user_nickname from game_project_tb as p,game_project_label_tb as l where l.name= :category and p.id = l.project_id and p.apply_status=1",nativeQuery=true)
@Query(value="SELECT bot_id FROM xiaodu_history_tb WHERE xiaodu_user_id=?1 ORDER BY last_time LIMIT 15",nativeQuery=true)
List<String>getHistory(StringxiaoduUserId);
@Query(value="SELECT DISTINCT xiaodu_user_id FROM xiaodu_history_tb",nativeQuery=true)
List<String>getAllUser();
@Transactional
@Query(value="delete from xiaodu_history_tb where xiaodu_user_id=?1 and last_time < (select last_time from xiaodu_history_tb where xiaodu_user_id=?1 order by last_time limit 14,1)",nativeQuery=true)
voiddeleteOverTime(StringuserId);
@Transactional
@Query(value="delete from xiaodu_history_tb where last_time <?1",nativeQuery=true)