title: SSIS - Derived Column - Substring/Charindex - Case when statement
body: <p>I've this SQL Code:</p>
  
  <pre><code>Select [Name] = case when CHARINDEX(''.'', [Name])&gt;0 
                              then LEFT([Name],CHARINDEX(''.'', [Name])-1)
                          else [Name] end,
          [System] = case when reverse(SUBSTRING(REVERSE( System),1,CHARINDEX('':'', REVERSE(System)))) like '':'' 
                              then (  System + ''\'')
                          else    System end
  </code></pre>
  
  <p>And I'm creating my SSIS workflow in order to build my ETL using SSIS. To create the transformations above I'm using a Derived Column Object.
  For the first statement I try this:</p>
  
  <pre><code>ISNULL(SUBSTRING([Name],1,FINDSTRING([Name],".",1) - 1)) ? [Name] : SUBSTRING([Name],1,FINDSTRING([Name],".",1) - 1)
  </code></pre>
  
  <p>But it gives me error...</p>
  
  <p>How can I make that two transformations?</p>
  
  <p>Thanks!</p>