1.引入
@Autowired
JdbcDao jdbcDao;
2.代码
String sqlForLive = "select * from live where user_id='"+id+"' and id !='"+liveId+"'";


List<ApiLiveEntity> liveList = jdbcDao.find(sqlForLive,ApiLiveEntity.class,null);


String updateSql = "UPDATE live SET live_state=0 where user_id='"+id+"' and id !='"+liveId+"'";


jdbcDao.executeSql(updateSql);
————————————————
版权声明:本文为CSDN博主「昊天卍上帝」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/qianyesoft001/java/article/details/77035724

相关文章:

  • 2021-09-18
  • 2021-06-23
  • 2021-12-19
  • 2021-06-28
猜你喜欢
  • 2021-10-25
  • 2021-12-17
  • 2021-11-02
  • 2021-12-18
  • 2021-05-07
  • 2021-12-30
相关资源
相似解决方案