title: SQL Server 2008 DBMS
body: <p>I need to add two column values from two different tables and second table will changed and affects the values in to database.</p>
  
  <ul>
  <li>First table is <code>SendStockByVendor</code>, columns are <code>product_name</code>, <code>Quantity</code></li>
  <li>Second table is <code>presentsupply</code>, columns are <code>product_name</code>, <code>Quantity</code></li>
  </ul>
  
  <p>That two values add and store in 2nd table or in database. But same <code>product_name</code> is the condition and remaining values of <code>presentsuppy</code> (table name) remain as it is.</p>
  
  <p>I ran the following query but it shows only same name values and quantity but remaining values are not shown.</p>
  
  <pre><code>select 
      p.Product_ID, p.Product_Name, p.Product_Cost, 
      p.Total_Cost, p.Product_Description, p.Quantity, 
      s.Quantity, 
      p.Quantity + s.Quantity as [Total]
  from  
      presentsupply p
  join 
      SendStockByVendor s on p.Product_Name = s.Product_Name; 
  </code></pre>