Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Calculate remainder of a division in Oracle

851268Apr 1 2016 — edited Apr 1 2016

Hello Folks

I am looking for a simple function which can calculate remainder of a division. For example if the function name is DIVIDE with parameters as (N1,N2) where N1 - Number to divide and N2 - Number with which N1 is to divide, then output of DIVIDE should be the remainder of the division. Simple mathematics division. No confusion of FLOOR or Ceiling. I have tried MOD and REMAINDER but not useful in my scenario.

Example, DIVIDE(663.81,3) should return me 0 and NOT 0.81 (which excel is returning me when I am using MOD function).

Any help would be really appreciate.

Thanks

S

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 29 2016
Added on Apr 1 2016
2 comments
580 views