title: cannot group same value together laravel
body: <p>so I have a function which is:</p>
  
  <pre><code>public function checkTS(Request $request, $companyID)
  {
    $data = DiraQuestion::where('status', 0)-&gt;get();
  
    return view('AltHr.Chatbot.checkTS', compact('data','companyID'));
  }
  </code></pre>
  
  <p>from here I output a table like:</p>
  
  <pre><code>&lt;table id="myTable" class="table table-striped"&gt;
    &lt;thead&gt;
      &lt;tr&gt;
        &lt;th&gt;&lt;/th&gt;
        &lt;th&gt;Entity Type&lt;/th&gt;
        &lt;th&gt;Entity Value&lt;/th&gt;
        &lt;th&gt;Synonym&lt;/th&gt;
        &lt;th&gt;&lt;/th&gt;
      &lt;/tr&gt;
    &lt;/thead&gt;
    &lt;tbody&gt;
    @foreach($data as $b)
      &lt;tr&gt;
        &lt;td&gt;&lt;input type="hidden" name="id" value="{{ $b-&gt;id }}" readonly&gt;&lt;/td&gt;
        &lt;td&gt;{{ucwords(strtok($b-&gt;eType, '_'))}}&lt;/td&gt;
        &lt;td&gt;{{ucwords($b-&gt;eVal)}}&lt;/td&gt;
        &lt;td&gt;{{ucwords($b-&gt;synonym)}}&lt;/td&gt;
        &lt;td&gt;&lt;a href="{{action('AltHr\Chatbot\ChatbotController@viewTS', [$companyID, $b-&gt;id, $b-&gt;eType, $b-&gt;eVal])}}" class="btn alt-btn alt-btn-black"&gt;View&lt;/a&gt;&lt;/td&gt;
      &lt;/tr&gt;
    @endforeach
    &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>currently, its showing me the output like:
  <a href="https://i.stack.imgur.com/uA2BA.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uA2BA.jpg" alt="output"></a></p>
  
  <p>and my database looks like:
  <a href="https://i.stack.imgur.com/FIQzN.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FIQzN.jpg" alt="db"></a></p>
  
  <p>as you can see from the first picture what I want to do is to group it together which has the same intent, eType, eVal from database so instead of showing all the values in the table it should only show 1 value which is already been group together by the same 3 value. how can I do that?</p>