title: Undefined method Illuminate\Database\Query\Builder::setPath()
body: <p>I am trying to call my table called "Carousel". But it's getting an error.
  I already created for my Model. I am using php myadmin.</p>
  
  <p>Error Message : </p>
  
  <blockquote>
    <p>undefined method Illuminate\Database\Query\Builder::setPath()</p>
  </blockquote>
  
  <p>Carousel model</p>
  
  <pre><code>&lt;?php
  namespace App;
  use Illuminate\Database\Eloquent\Model;
  class Carousel extends Model
  { 
  
  }
  </code></pre>
  
  <p>Controller</p>
  
  <pre><code>function getsearchCarousel(Request $req){
  
      if($req-&gt;has('searchcar')){
          $data = Carousel::where('carouselName','like',$req-&gt;input('searchcar').'%')-&gt;select('id','carouselName, carouselPhoto');
          $data-&gt;setPath($req-&gt;url()."?searchcarousel=".$req-&gt;searchcar);
          return view('Admin.Page.Carousel.carousel')-&gt;with('data', $data);
      }
      else{
          return redirect('/Admin/Page/carousel');
      }
  }
  </code></pre>