title: Java Double getting initialized to 0.0
body: <p>I have a bean where I have a field "CustAmount "which is double, I tried testing the bean and i dont seem to understand this: When i run on my local machine it gets initialized to 0.0 when instantiated. When i run the same code in my linux test environment it remains null. due to which there is a difference in the retrieved data meaning if i send the CustAmount as null to my Backend i get some data but if i send the CustAmount as 0.0 the query is done on the basis of 0.0 and sends me nothing back. </p>
  
  <p>How is this possible if the code is same, By any chance is it possible that when i do new MyBean() compiled in java 1.5 the double remains null and in 1.6 it gets initialized to 0.0.</p>
  
  <p>I dont know if this is something that happens in two Java versions but thats the only difference on my end.</p>
  
  <p>Thanks for any hint.</p>
  
  <p>Adding code snippet :</p>
  
  <pre><code>public class MyBean {
  
  private double custAmount;
  
      public void setCustAmount(double custAmount) {
          this.custAmount = custAmount;
      }
  public double getCustAmount() {
          return custAmount;
      }
  
  }
  </code></pre>
  
  <p>And I just do </p>
  
  <pre><code>MyBean mybean =  new MyBean();
  </code></pre>
  
  <p>its not a Double but a double.
  Syed.. </p>