Hitachi Vantara Pentaho Community Forums
Results 1 to 4 of 4

Thread: Calculations in Kettle

  1. #1

    Default Calculations in Kettle

    I'm sure there will be a very obvious reason for this but I would like to know why when I divide
    -277125/187250
    in the calculator on two big number fields it returns -1 and not -1.47 when all my positive calculations return decimal places.

    I'm sure someones about to tell me I'm a dumbass but thanks anyway.

    Tom

  2. #2
    Join Date
    May 2006
    Posts
    4,882

    Default

    And screwy users ... kidding. There was an explanation in the FAQ on the calculations in the calculator step, but that may have to be revised since a couple of weeks.

    In your case... my current hunch is that your both inputs are integer and the output is integer so the result gets chopped. Try using Number, you will get what you expect.

    Regards,
    Sven

  3. #3

    Default

    Cheers Sven

    All my figures were set to BigNumber and reverting them to Number worked, apart from allowing more figures in BigNumber how do they differ?

    Cheers

    Tom

  4. #4
    Join Date
    May 2006
    Posts
    4,882

    Default

    Number is Double internally, BigNumber is BigDecimal internally.

    Regards,
    Sven

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.