title: Create INDEX on Table Variable
body: <p>I'm trying to create an index on a table variable, is this possible?</p>
  
  <pre><code>DECLARE @RDTABLE TABLE (TLCDE VARCHAR(12), TLTYP VARCHAR(2), TLEFFDAT DATETIME, TLRATFCT DECIMAL(29,6))
  
  INSERT INTO  
      @RDTABLE
  SELECT
      TLCDE
  ,   TLTYP
  ,   TLEFFDAT
  ,   TLRATFCT
  FROM    
      BT_TR
  WHERE
      TLTYP = 'TX'
  </code></pre>
  
  <p>Normally I would create the index like so:</p>
  
  <pre><code>CREATE NONCLUSTERED INDEX IX_RDTABLE ON RDTABLE ([TLTYP],[TLEFFDAT]) 
  INCLUDE ([TLCDE],[TLRATFCT]) 
  </code></pre>