[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

RE: [sqr-users] Have a doubt in rounding




Thanks Gina. That solved the problem. As you mentioned, the problem was
with the display mask and not edit.

Thanks again.

Regards
KM Narayanan




"Bencke, Gina" <GinaBencke@forestcity.net>@sqrug.org on 07/13/2004
01:43:08 PM

Please respond to "This list is for discussion about the SQR database
       reporting  language from Hyperion Solutions." <sqr-users@sqrug.org>

Sent by:    sqr-users-bounces+kaz.narayanan=averydennison.com@sqrug.org


To:    "This list is for discussion about the SQR database
       reportinglanguage from Hyperion Solutions." <sqr-users@sqrug.org>
cc:

Subject:    RE: [sqr-users] Have a doubt in rounding

I doubt you are actually having trouble rounding, instead it is a issue
of edit display edit masks.  SQR is using the default numeric edit mask
to show the value of #RMR04, which unless you changed it has 5 places
after the decimal point.  The edit mask  does not change the value of
#RMR04, it simply controls the manner in which the number is displayed
or printed. (I am assuming your output is something like 123.45000)  Try
using and edit mask on the show statement.

SHOW 'tHE RMR AFTER  ROUNDING ' #RMR04 edit 999.99


Hope this helps,

Gina Bencke
Bencke Consulting Corporation

Office (440) 519-0060
email: gina.work@bencke.com

-----Original Message-----
From: sqr-users-bounces+ginabencke=forestcity.net@sqrug.org
[mailto:sqr-users-bounces+ginabencke=forestcity.net@sqrug.org] On Behalf
Of Kaz.Narayanan@averydennison.com
Sent: Tuesday, July 13, 2004 4:20 PM
To: sqr-users@sqrug.org
Subject: [sqr-users] Have a doubt in rounding


Hi,

I am trying to edit a character filed and convert them as numbers. Even
thought I give 2 floating points, I still get 5 floating points.

Given below is an example:

            let $RMR04  = $input_file
            show 'The Last RMR filed is ' $RMR04
            let #RMR04 = to_number($RMR04)
            let #RMR04  =  round(#RMR04 ,2)
            SHOW 'tHE RMR AFTER  ROUNDING ' #RMR04

Even though I have rounded my numeric variable in 2 digits, the show
statement returns 5 digits.

Please let me know If I am making a mistake.

Regards

KM Narayanan





-----------------------------------------
The information transmitted is intended only for the person or entity to
which it is addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by persons or
entities other than the intended recipient is prohibited. If you
received this in error, please contact the sender and delete the
material from any computer.


_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org http://www.sqrug.org/mailman/listinfo/sqr-users



_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users






-----------------------------------------
The information transmitted is intended only for the person or entity
to which it is addressed and may contain confidential and/or
privileged material. Any review, retransmission, dissemination or
other use of, or taking of any action in reliance upon, this
information by persons or entities other than the intended recipient
is prohibited. If you received this in error, please contact the
sender and delete the material from any computer.


_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users