Преглед изворни кода

document of FindAndCount()

xormplus пре 6 година
родитељ
комит
80b0b9cef7
1 измењених фајлова са 7 додато и 0 уклоњено
  1. 7 0
      README.md

+ 7 - 0
README.md

@@ -1175,6 +1175,13 @@ counts, err := engine.Count(&user)
 // SELECT count(*) AS total FROM user
 ```
 
+* `FindAndCount` combines function `Find` with `Count` which is usually used in query by page
+
+```Go
+var users []User
+counts, err := engine.FindAndCount(&users)
+```
+
 * 条件编辑器
 
 ```Go