Spring Boot | Pagination and Sorting With Spring Data JPA | JavaTechie

Spring Boot | Pagination and Sorting With Spring Data JPA | JavaTechie

Java Techie

2 года назад

119,251 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Jayakumar Sivasankar
Jayakumar Sivasankar - 18.10.2023 19:07

Great explanation and we are able to understand easily. Thanks a lot!!

Ответить
Yi Ting Chen
Yi Ting Chen - 17.08.2023 19:40

thanks,vary helpful

Ответить
marchevka22
marchevka22 - 01.08.2023 21:18

Does anyone know if Pagination works similarly with Spring JDBC or Spring Data?

Ответить
marchevka22
marchevka22 - 01.08.2023 21:17

As I'm understanding the last example, PaginationAndSort first sorts all records, then paginates the result. This is what I would want and expect.

Ответить
Shubham Salunkhe
Shubham Salunkhe - 21.06.2023 21:54

If sorting is not used in pagination will it alter the result if hit multiple times suppose say in page0 A,B came and again query hit with page1 B,C came so here B came again. Is it the possibility?

Ответить
Chetan Bhandari
Chetan Bhandari - 02.05.2023 23:56

Thanks Basant !! Awesome explanation on the implementation with example

Ответить
Gautam Chatterjee
Gautam Chatterjee - 20.03.2023 10:52

Nice explanation. But I have a question here. If in pagination, suppose the first page shows records from id 1-10 in asc order. So as per this logic will that not alter the results shown in the first page if the sorting is applied to descending?

Ответить
Tú Nguyễn
Tú Nguyễn - 08.03.2023 12:24

Thank you so very much!

Ответить
Franco Vedia
Franco Vedia - 01.03.2023 03:36

Thanks

Ответить
Gaurav Kumar
Gaurav Kumar - 07.02.2023 13:57

Best video !!!!!!!!!!!!!!!!!!!!!

Ответить
Võ Quốc Trọng
Võ Quốc Trọng - 06.02.2023 16:28

thanks very much!!

Ответить
ROSHAN PATRO
ROSHAN PATRO - 17.01.2023 16:12

So so so helpful, sir!! Thank you very much 🙇‍♂

Ответить
Fahad Qureshi
Fahad Qureshi - 13.01.2023 14:57

I have 137 data in database and when i entered api/3/50 it should show me 37 data but it shows me empty content[]. what will i do?

Ответить
Chris Holland
Chris Holland - 28.12.2022 18:01

Good explanation on the implementation of offset pagination in Spring. However, please use query parameters in the controller end instead of path variables. Query params are meant for filtering, sorting, and pagination.

Ответить
Tantrax 007
Tantrax 007 - 26.12.2022 15:45

Thank you so much friend!

Ответить
Max
Max - 19.12.2022 03:47

Just want to call out couple of things. Sorting field, page size and offset are usually accepted as query params and not the path params. Path params are used for resource ids.

Ответить
Dummy Demo
Dummy Demo - 08.12.2022 10:28

i also use postconstruct
but after run the application data is not created my sql table
can u plzz explain
how to resolve this problem
or we manually insert data

Ответить
Shivam Sharma
Shivam Sharma - 25.11.2022 13:12

good video, can you please explain about APIResponse how it works on multiple types (T)

Ответить
Raghav Sharma
Raghav Sharma - 31.10.2022 21:52

Thanks sir for this great explaination.
But I am receiving "[ ]", when I retur the Page<> object as response.
When I pass the List of contents inside the Page as response I get the data, but when I return the object of Page<> i get "[ ]".
What could be the reason, please help.

Ответить
Thunder ⚡
Thunder ⚡ - 12.10.2022 19:59

nice explanation

Ответить
Arvind G
Arvind G - 01.10.2022 21:54

Boss u r great

Ответить
HenrryWith2Rs
HenrryWith2Rs - 29.09.2022 07:16

Thank you so very much. This was exactly what I needed.

Ответить
vinod kumar thakur
vinod kumar thakur - 23.09.2022 21:45

thank you very much

Ответить
grr lgd
grr lgd - 17.08.2022 11:06

Java Techie is great !!!

Ответить
prabakar .u
prabakar .u - 22.07.2022 22:13

Thanks

Ответить
WL Phantom
WL Phantom - 12.07.2022 10:28

可惜没有中文字幕

Ответить
Gaurav Gupta
Gaurav Gupta - 20.06.2022 05:20

With findAll, we can use pagination bcos it has overloaded method but what if there is custom method? How to use pagination?

Ответить
Fun with Ronak
Fun with Ronak - 18.06.2022 10:29

Nice video exactly what i looking for ,it will be good if you add also one more condition "sorting with multiple column" but thats fine

Ответить
Rendezvous
Rendezvous - 07.06.2022 21:49

nice

Ответить
Lakshmi Srinivasarao Chatla
Lakshmi Srinivasarao Chatla - 05.06.2022 12:37

Thank you Basant..very nicely explained the pagenation

Ответить
Ravi Kumar Grandhi
Ravi Kumar Grandhi - 04.06.2022 22:29

If you have null values in db table column. Here how you will sort data in query?

Ответить
Manjunath k
Manjunath k - 07.04.2022 20:19

How to consume all the data from paginated API via rest template

Ответить
Raj
Raj - 05.04.2022 21:57

.withSort doesnot found
how to solve it?

Ответить
Meeran M
Meeran M - 29.03.2022 12:59

Its really a great tutorial...... and you present very well.

Ответить
GVB TELUGU CHANNEL
GVB TELUGU CHANNEL - 29.03.2022 06:18

how can we implement pagination and filter with dynamic JPA/native query

Ответить
David
David - 24.03.2022 05:52

Me salvaste el día bro, muchísimas gracias :3

Ответить
Ali Masoumi
Ali Masoumi - 13.03.2022 18:07

Thank you boy
You're perfect

Ответить
kiran kumar Mandarapu
kiran kumar Mandarapu - 10.03.2022 12:54

Hi Bro,
In controller class at line "new APIResponse<>(allProducts.size(),allProducts) " I am getting below compilation error
CANNOT INFER TYPE ARGUMENTS FOR APIRESPONSE . Please help me how to resolve this

Ответить
Dipika Gupta
Dipika Gupta - 08.03.2022 10:06

Instead of passing page size and offset, can we just see the hard coded 5 no. of elements in one page and click enter and then see other pages one by one till end?

Ответить
kiran kumar Mandarapu
kiran kumar Mandarapu - 28.02.2022 13:10

Hi Brother,
I have tried to implement same, but not able to get PageRequest in my project. Please let me know how to add dependency in my projejct?

Thanks & Regards,
Kiran Mandarapu

Ответить
samke tola
samke tola - 18.02.2022 05:09

can we using jQuery datatables on frontend?

Ответить
Saud Siddiqui
Saud Siddiqui - 30.01.2022 12:30

How to implement UI for this server side pagination and sorting like you showed in this video? Is UI code is also shared?

Ответить
Shakib TTT
Shakib TTT - 23.01.2022 16:09

thanks boss

Ответить
Castuh
Castuh - 17.01.2022 06:09

Thanks!

Ответить
DutGi
DutGi - 12.01.2022 14:16

Thanks awesome

Ответить
Coder Toaster
Coder Toaster - 30.12.2021 22:09

Pagination will only work with predefined queries ?
Or does it work with our custom named queries as well ?

Ответить
Raghavendra C
Raghavendra C - 14.12.2021 20:55

Plzzz make vedio with the same concept with the help of using criteria api means creating our own user repository and providing implement for that with the help of criteria builder , without extending jpa r crud repository

Ответить
Aditya Kumar
Aditya Kumar - 09.11.2021 09:07

Thank you

Ответить
Unemployed CSE
Unemployed CSE - 27.10.2021 21:28

Awesome

Ответить