title: How to get column value from single active record object
body: <p>I get Issue object from a table</p>
  
  <pre><code>@issue = Issue.where(id: issue_id)
  </code></pre>
  
  <p>So I have the next active record object.</p>
  
  <pre><code>ActiveRecord::Relation::WhereClause:0x00007f88ea670f00 @predicates=[#&lt;Arel::Nodes::Equality:0x00007f88ea670fa0 @left=#&lt;struct Arel::Attributes::Attribute relation=#&lt;Arel::Table:0x00007f88ea05fe68 @name="issues", @type_caster=#&lt;ActiveRecord::TypeCaster::Map:0x00007f88ea05fee0 @types=Issue(id: integer, tracker_id: integer, project_id: integer, subject: string, description: text, due_date: date, category_id: integer, status_id: integer, assigned_to_id: integer, priority_id: integer, fixed_version_id: integer, author_id: integer, lock_version: integer, created_on: datetime, updated_on: datetime, start_date: date, done_ratio: integer, estimated_hours: float, parent_id: integer, root_id: integer, lft: integer, rgt: integer, is_private: boolean, closed_on: datetime)&gt;, @table_alias=nil&gt;, name="id"&gt;, @right=#&lt;Arel::Nodes::BindParam:0x00007f88ea670fc8 @value=#&lt;ActiveRecord::Relation::QueryAttribute:0x00007f88ea670ff0 @name="id", @value_before_type_cast=1, @type=#&lt;ActiveRecord::ConnectionAdapters::SQLite3Adapter::SQLite3Integer:0x00007f88e6cd3950 @precision=nil, @scale=nil, @limit=nil, @range=-9223372036854775808...9223372036854775808&gt;, @original_attribute=nil&gt;&gt;&gt;]&gt;}
  </code></pre>
  
  <p>with <code>project_id: integer</code> column, but when I tried to get project_id value - it threw an error</p>
  
  <p>My code:</p>
  
  <pre><code>project_id = @issue.project_id
  </code></pre>
  
  <p>Error:</p>
  
  <pre><code>NoMethodError (undefined method `project_id' for #&lt;Issue::ActiveRecord_Relation:0x00007fdb03e0e008&gt;
  Did you mean?  object_id):
  </code></pre>