472,142 Members | 1,261 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,142 software developers and data experts.

Cast decimal point for the division of 2 decimal fields

Hi, when I divide Sum (AMT_NET_GAAP_GNLS)/Sum (AMT_UPB_FM) and these two fields are decimal fields, the results is 0

I know there is a way to cast the decimal point but i keep on getting errors,
How do I cast decimal (14,13) for the result of

from udbadm.mol_cl_closd_hst
Where dt_sts_closd between '08/01/2006' and '08/31/2006' and date (dt_srce_end) = '01-01-9999'
and flag_del <>'Y'and cd_mrtg_ls_type = 'REO'
GROUP BY CD_FM_RGN, ind_unit
Oct 28 '06 #1
1 5967
4,258 Expert 4TB
I don't see why the decimals are cut off, but what about using the FORMAT()? As in
Expand|Select|Wrap|Line Numbers
  1. SELECT FORMAT(0.0004 / 0.0123, 10)
Ronald :cool:
Oct 28 '06 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

18 posts views Thread by Graham Nicholls | last post: by
21 posts views Thread by Batista, Facundo | last post: by
7 posts views Thread by hana1 | last post: by
687 posts views Thread by cody | last post: by
9 posts views Thread by Nicolas Blais | last post: by
8 posts views Thread by Byte | last post: by
12 posts views Thread by Frank Millman | last post: by
13 posts views Thread by =?Utf-8?B?RXRoYW4gU3RyYXVzcw==?= | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.