Re: Printing Floating Decimal numbers
Posted in 1994
Dennis Pimple in message <dennisp.769285500@puma> writes: : : colin@scdipc0.ueci.com (Colin Mcgrath) writes: : : >We store numeric data in a floating decimal point numeric column: DECIMAL(8) : >We can unload the data and it unloads fine: 123.456 or 12.345678 or 12345.0 : >In SQL Query, we can select and display the data as it was typed in, once : >the environmental variable "DBFLTMASK" is set to "-1" : : >In 4GL screens and reports, is there any way to format the output to display : >the data as it was typed in and as it unloads and as it displays in SQL? : >Currently, I format it into character data with a USING "<<<<<<<&.########" : >then, in a FOR loop, strip off trailing zeros past the decimal point. : >Not the same as the original numbers, if the zeros were significant. : : Why not take your scheme one step further by making the input a CHAR field, : then reading what they input to create the USING string to display it with? : That is in fact how I originally get the input. It's getting it back out of the database table for subsequent displays and updates that perplexes me. I don't know how to retrieve the data in a way that preserves the originally entered number of trailing zeros. -- Colin McGrath Internet: colin@scdipc0.ueci.com Raytheon Engineers & Constructors Inc. UUCP: ..!uunet!trac2000!trac3000!cmm 30 S. 17th St Voice: 215-422-3449 Philadelphia, PA, 19101 FAX: 215-422-4095