# Pagination counting upwards

**URL:** <https://www.ruby-forum.com/t/pagination-counting-upwards/173624>\
**Category:** Rails\
**Created:** [August 12, 2009, 8:45am UTC](https://www.ruby-forum.com/t/pagination-counting-upwards/173624 "2009-08-12T08:45:58Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tdellaringa](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/7bcc69/32.png) [@tdellaringa](https://www.ruby-forum.com/u/tdellaringa)\
**Post date:** [August 12, 2009, 8:45am UTC](https://www.ruby-forum.com/t/pagination-counting-upwards/173624/1 "2009-08-12T08:45:58Z")

</div>

Hey I have a question on paginations. I got it working on the part of  
my application in which users submit posts, but I want it to be used in  
a way that counts up, so that the first post would always be on page  
one, and as they got into newer posts, say post 100, it would be on page  
10. This way users would always know what page their post was on and it  
wouldn’t change as more posts were submitted. Anyone who has any info  
on how to do this, it would be appreciated!

---

<div class="post-metadata">

**Author:** ![tdellaringa](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/7bcc69/32.png) [@tdellaringa](https://www.ruby-forum.com/u/tdellaringa)\
**Post date:** [August 12, 2009, 8:59am UTC](https://www.ruby-forum.com/t/pagination-counting-upwards/173624/2 "2009-08-12T08:59:47Z")

</div>

Tom D. wrote:

> Hey I have a question on paginations. I got it working on the part of  
> my application in which users submit posts, but I want it to be used in  
> a way that counts up, so that the first post would always be on page  
> one, and as they got into newer posts, say post 100, it would be on page  
> 10. This way users would always know what page their post was on and it  
> wouldn’t change as more posts were submitted. Anyone who has any info  
> on how to do this, it would be appreciated!

In your model, instead of fetching the records in descending order,  
fetch it in ascending order. This way, 10th page will have 100th post (  
assuming each page displays 10 records in ascending order)
