title: SQL Select - Calculated Column if Value Exists in another Table
body: <p>Trying to work through a SQL query with some very limited knowledge and experience. Tried quite a few things I've found through searches, but haven't come up with my desired result.</p>
  
  <p>I have four tables:</p>
  
  <pre><code>ORDERS
  [ID][DATE]
  
  ORDER_DETAILS
  [ID][ITEM_NO][QTY]
  
  ITEMS
  [ITEM_NO][DESC]
  
  KITS
  [KIT_NO][ITEM_NO]
  </code></pre>
  
  <p>Re: KITS - [KIT_NO] and [ITEM_NO] are both FK to the ITEMS table. The concatenation of them is the PK.</p>
  
  <p>I want to select ORDERS, ORDERS.DATE, ORDER_DETAILS.ITEM_NO, ITEMS.DESC</p>
  
  <p>No problem. A few simple inner joins and I'm on my way. </p>
  
  <p>The difficulty lies in adding a column to the select statement, <code>IS_KIT</code>, that is true if:</p>
  
  <p><code>EXISTS(SELECT null FROM KITS WHERE KITS.ITEM_NO = ORDER_DETAILS.ITEM_NO)</code>.</p>
  
  <p>(if the kits table contains the item, flag this row)</p>
  
  <p>Is there any way to calculate that column?</p>