title: Convert scientific notation back to numbers in SQL Server
body: <p>I had data in Excel like</p>
  
  <pre><code>7540006
  7540447
  </code></pre>
  
  <p>But when I import the data into <code>SQL Server</code>, it is saved as </p>
  
  <pre><code>7.54001e+006
  7.54045e+006
  </code></pre>
  
  <p>So now when I try to convert it to back to original state, it's not ending up with the correct value.</p>
  
  <p>I have tried following queries for conversion</p>
  
  <pre><code>declare @a varchar(40)
  set @a = '7.54001e+006'
  
  declare @b decimal(27, 12)
  
  SELECT @b = CONVERT(REAL, @a, 2)
  
  SELECT LTRIM(RTRIM(str(@a))), LTRIM(STR(@a))
  
  SELECT CAST('7.54001e+006' as REAL)
  </code></pre>
  
  <p>and the output I am getting is addition of 3 to original value for all methods
  i.e.</p>
  
  <pre><code>7540010
  7540050
  </code></pre>
  
  <p>How do I convert it back to original state ??</p>