title: Laravel - Bind parameters when using DB::raw() on a join
body: <p>I have a query that requires a join using <code>DB::raw()</code>. It's joining a <code>JSON_TABLE()</code> so it's a little different compared to what people normally do. I've got it working but I can't seem to get it to work when binding parameters.</p>
  
  <p>Here's the code:</p>
  
  <pre class="lang-php prettyprint-override"><code>if(!isset($request-&gt;search['merchantId']) &amp;&amp; isset($request-&gt;search['uuid']['division'])) {
  
    $query-&gt;join(DB::raw('JSON_TABLE(
                        \'[{"division":"'.$request-&gt;search['uuid']['division'].'"}]\',
                        \'$[*]\' COLUMNS (
                                division VARCHAR(32) PATH \'$.division\'
                            )
                        ) jt1'), 'jt1.division', 'entitiesConsolidation.division');
  }
  </code></pre>