Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Fixed point arithmetic - activate in coding?

Former Member
0 Likes
6,057

Hi there,

I have a question. I am adding coding to an include of SAP (modification). In this include SAP has disabled the checkbox for the Fixed point arithmetic in the attributes. Now I have the problem that I want to activate this flag for my inserted coding and after my coding I want to set it back to the original value.

Is there any statement that gives me this option in ABAP for example?

Thank you very much.

Kind regards

Max

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
2,298

I'm guessing you are doing some calculations that you need higher precision to do properly.

Instead of doing your code in the SAP program, you can call a Z function module with the attribute checked. This will leave less work at upgrade time as well.

Rob

3 REPLIES 3
Read only

Former Member
0 Likes
2,298
I want to activate this flag for my inserted coding 
and after my coding I want to set it back to the original value.

This not makes any sense.

Since you will again set Fixed point arithmetic's value back to original,

than what would impact to your piece of code?

As include always associate with some other main program,

and it will only execute once the main program executes.

And after set the Fixed point arithmetic back to original, do you think you will find any change?

Read only

Former Member
0 Likes
2,299

I'm guessing you are doing some calculations that you need higher precision to do properly.

Instead of doing your code in the SAP program, you can call a Z function module with the attribute checked. This will leave less work at upgrade time as well.

Rob

Read only

0 Likes
2,298

Hello Rob,

as I'm currently having the same question, I valued your answer with the function module, as this could solve my requirement as well, as I temporarily need more precision within a calculation. I could also use other ABAP data types, moving the variable's content back and forth.

But I also wonder, if there's an in-line statement, e.g.

set extended check off/on

... that is similar to the check-box "fixed point arithmetic", so you could temporarily switch the attribute at runtime.

Any ideas here?

Florin