Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Sort key

Along with partition key table may have a sort key. In order to declare it in a model range class method should be used:

class Post
  include Dynamoid::Document

  range :posted_at, :datetime
end

Second argument, type, is optional. Default type is string.