nestjsx / nestjs-typeorm-paginate

:page_with_curl: Pagination response object function + types for typeorm + nestjs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Paginate with queryBuilder counts raw number of rows instead of entity number of rows.

linconsdev opened this issue · comments

image

This is the meta output for only 40 rows of one entity. Im using queryBuilder and leftJoinAndMapOne and mapMany to get relationships.
I don't understand where this totalItems number 2559 is coming from.
It is easy to replicate, happens on every queryBuilder I've made.

Can this issue be addressed?

Can we have this solution merged into actual package?

I am also facing the same similar issue related limit i should get 20 results but ended up getting 3 only i am using subquery way but query results coming fine but problem with pagination

Screenshot 2023-09-12 at 11 53 34 AM

@linconsdev or @bashleigh , please consider closing this issue as a duplicate of 627.