title: Converting a comma-separated varchar to decimal
body: <p>I have a column in database like;</p>
  
  <pre><code>new_profittl
  ------------
  45,1000
  84,0400
  156,6500
  169,1800
  ...
  </code></pre>
  
  <p>My code;</p>
  
  <pre><code>SELECT SUM(CAST(new_profittl as DECIMAL(18,2)))
  FROM new_hotelreservation AS R
  WHERE DATEADD(hour, DATEDIFF(hour, getUTCdate(), GETDATE()),R.new_salesdate)
        BETWEEN @bas AND @bit AND R.statecode=0
  </code></pre>
  
  <p>I have to sum this field. The field is NVARCHAR and separated with comma, not dot. so I can't sum this field. I tried to convert or to cast to decimal but it didn't. It gave an error 'Error converting data type nvarchar to numeric.'.</p>
  
  <p>How could I sum this field?</p>