Post by abrsvc Post by Arne Vajhøj
Is NASDAQ still using NonStop?
That article doesn't make sense unless the value is stored as the
number of 1000ths of cents per share as an integer value. In this
case, the actual value would be displayed inserting the decimal point
in the proper place. This is one of the reasons that Cobol is still
used in finance because of packed decimal where there is really no
limit to the number of digits.
That is what they say in the article.
This is explained because its algorithm saves stock prices as a 32-bit
number, which takes up less memory and makes the software more efficient.
In this format, the highest possible number is 2 ^ 32 -1, or
4,294,967,295, according to Gizmondo . But since Nasdaq records prices
to four decimal places, the largest figure it can store is the one quoted.
There are plenty of solutions. Even a 64 bit integer would have done it.
PS: I don't think Cobol BCD size is unlimited - just more than big
enough for this case.