Receiving exponent in incoming value: Suggest Urgent

Imported from previous forum

Hi,
We have implemented a fix for receiving a message. The problem we are facing that we are receiving exponent value in on of our incoming message.
e.g. 9.99999999999446E-4

instead of it should be 0.0010.

what setting we need to do?

Please suggest!! its very urgent

Hi,
We have implemented a fix for receiving a message. The problem we are facing that we are receiving exponent value in on of our incoming message.
e.g. 9.99999999999446E-4

instead of it should be 0.0010.

what setting we need to do?

Please suggest!! its very urgent

Numbers with exponents (…E-4) are not supported by the FIX protocol.
While your program formats these numbers in this way depends on your
programming language / library.

Cheers, Jörg

It sounds like you are using a floating-point data type to read a decimal value. Floating-point types should not be used for this, especially in financial applications.

Some questions to confirm:

  1. What programming language are you using?
  2. Have you checked the actual FIX message (in text form)?
  3. What data type are you using for the tag value?

References:

http://my.safaribooksonline.com/book/programming/java/9780137150021/general-programming/ch08lev1sec4

If you are using Java, I recommend you use BigDecimal for all decimal number values.

Hope this helps!

Cheers,
Will.

Hi,
We have implemented a fix for receiving a message. The problem we are facing that we are receiving exponent value in on of our incoming message.
e.g. 9.99999999999446E-4

instead of it should be 0.0010.

what setting we need to do?

Please suggest!! its very urgent