I'm new to rails, so excuse me if this is a silly/simple question - It appears that rails is doing the annoying way of ordering items, with 10 - 19 following 1, 20-29 following 2, etcetera.
Does anyone know of a way to make it logically order id's?
I'm new to rails, so excuse me if this is a silly/simple question - It appears that rails is doing the annoying way of ordering items, with 10 - 19 following 1, 20-29 following 2, etcetera.
Does anyone know of a way to make it logically order id's?
class CreatePosts < ActiveRecord::Migration def self.up create_table :posts do |t| end end
def self.down drop_table :posts end end
I've been using CocoaMySQL for managing the tables directly, as well.
I'm trying to call posts.id with classic pagination, namely
@post_pages, @posts = paginate :posts, :order => 'id', :per_page => 10