ActiveRecord::UnknownPrimaryKey

class ActiveRecord::UnknownPrimaryKey

Parent:
ActiveRecord::ActiveRecordError

Raised when a primary key is needed, but not specified in the schema or model.

Attributes

model[R]

Public Class Methods

new(model) Show source
Calls superclass method
# File activerecord/lib/active_record/errors.rb, line 207
def initialize(model)
  super("Unknown primary key for table #{model.table_name} in model #{model}.")
  @model = model
end

© 2004–2016 David Heinemeier Hansson
Licensed under the MIT License.

在线笔记
App下载
App下载

扫描二维码

下载编程狮App

公众号
微信公众号

编程狮公众号

意见反馈
返回顶部