Re: Precision problem
Posted in 1995
Bonnie, You wrote: > > I spoke with Informix technical support on Friday and was told to set > the environmental variable DBFLTMASK to -1. I did this. Oddly, I > cannot find any reference to this variable in my Informix manuals. Once > this variable was set, a query in Query-Language gave me actually values > for my data, but the report-writer still gave me only two decimal > places. I can sort of get around the problem with a "using" statement, > but that gives me pseudo-precision on values which do not actually have > twelve significant decimal places. > > One more piece of information: the fields in question are of data-type > float. I've tried passing them through variables of types character and > decimal in the report and that doesn't work either. > I ran into this problem awhile ago also. Jonathan Leffler suggested a workable solution. We enter the data in the screens as CHAR, then test that the data is numeric, then walk through the character variable and generate a "USING" char field that has the correct number of digits to the left and right of the decimal point, and finally store the data as a decimal and store the "USING" char field as a separate field along with it so later on we still know how the data should be displayed. -- Colin McGrath Internet: cmm@trac3000.ueci.com Raytheon Engineers & Constructors, Inc. Voice: 215-422-4144 Philadelphia, PA, 19101 FAX: 215-422-1445 <Standard disclaimers apply>