Eloquent get only one column as an array
<p>How to get only one column as one dimentional array in laravel 5.2 using eloquent?</p>

<p>I have tried: </p>

<pre><code>$array = Word_relation::select('word_two')-&gt;where('word_one', $word_id)-&gt;get()-&gt;toArray();
</code></pre>

<p>but this one gives it as 2 dimentional array like:</p>

<pre><code>array(2) {
      [0]=&gt;
      array(1) {
        ["word_one"]=&gt;
        int(2)
      }
      [1]=&gt;
      array(1) {
        ["word_one"]=&gt;
        int(3)
      }
    }
</code></pre>

<p>but I want to get it as:</p>

<pre><code>array(2) {
    [0]=&gt;2
    [1]=&gt;3
}
</code></pre>