亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定

查詢分頁失敗

@Test
public?void?selectPage()?{
????QueryWrapper<RtkHistory>?queryWrapper?=?new?QueryWrapper<RtkHistory>();
????queryWrapper.apply("date_format(create_time,'%Y-%m-%d')=?{0}"?,"2021-12-09")
????????????.and(i?->i.eq("name","溫濕度")).and(i?->i.eq("name2","temp?="));

????Page<RtkHistory>?Page?=?new?Page<RtkHistory>(1,?5);
????Page<RtkHistory>?iPage?=?rtkHistoryMapper.selectPage(Page,?queryWrapper);
????System.out.println("總頁數:"?+iPage.getPages());
????System.out.println("總記錄數:"?+iPage.getTotal());
????List<RtkHistory>?historyList?=?iPage.getRecords();
????for?(RtkHistory?rtkHistory?:?historyList)?{
????????System.out.println(rtkHistory);
????}

''TRACE<==? ? ? ? Row: 4356, 117, 溫濕度, 16.7, 2021-12-09 21:16:30

''TRACE<==? ? ? ? Row: 4367, 117, 溫濕度, 16.7, 2021-12-09 21:17:10

''DEBUG<==? ? ? Total: 222

'總頁數:0

總記錄數:0

RtkHistory(id=1969, pid=117, name=溫濕度, body=16.3, createTime=2021-12-09T14:35:01)

RtkHistory(id=1979, pid=117, name=溫濕度, body=15.2, createTime=2021-12-09T14:35:41)

RtkHistory(id=1990, pid=117, name=溫濕度, body=15.2, createTime=2021-12-09T14:36:21)

RtkHistory(id=2001, pid=117, name=溫濕度, body=15.2, createTime=2021-12-09T14:37:01)

RtkHistory(id=2012, pid=117, name=溫濕度, body=15.3, createTime=2021-12-09T14:37:41)

RtkHistory(id=2023, pid=117, name=溫濕度, body=15.3, createTime=2021-12-09T14:38:21)

RtkHistory(id=2034, pid=117, name=溫濕度, body=15.3, createTime=2021-12-09T14:39:01)


正在回答

1 回答

https://baomidou.com/pages/8f40ae/

這里是新的分頁插件的配置方法,要確保分頁插件的配置被spring正確加載

0 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消

查詢分頁失敗

我要回答 關注問題
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號