title: Laravel : Getting Single value from the database using pluck
body: <p>Hi everyone I'm using Laravel and I'm trying to get a single value from the database using <code>pluck</code>,
  the issue is the query must be written in the Laravel way not the normal sql.so how to write this
  sql query in Laravel ? I want to be able use <code>AS</code> to change the column name and <code>SUM</code>.all I want actually is to get the value from <code>total_quantity</code> column to do that I have to use pluck.
  any idea how to write that query ? </p>
  
  <p>Thanks in advance.</p>
  
  <pre><code>$PhysicalStock=DB::select("select sum(quantity) as `total_quantity` from InOutProducts where productID=$productID and InAndOut=1;")-&gt;pluck('total_quantity');
  </code></pre>