Skip to main content
Question

Why does the calculation result change?

  • Jan 27, 2022 5:36 AM UTC
  • 6 replies
  • 176 views

syntax[A]=1,syntax[B]=934

patern1: syntax[A]/934=0.0010706638115631692

patern2: 1/syntax[B]=0.0010706638115631692

patern3: syntax[A]/syntax[B]=0.023554603854389723

​

Only patern3 will give different results...

Please tell me the solution.

6 replies

  • Jan 27, 2022 6:43 PM UTC

Hello,

 

Could you please attach screenshot from the last calculation? I've done it in PQL and everything seems to be fine.

It was done in SQL?

 

Calculation 

Best Regards,

Mateusz Dudek


  • Jan 28, 2022 12:22 AM UTC

Hello.

Thank you for answering.

I uploaded a screenshot.

 

It was done in SQL?

>>>Yes

 

What's wrong?

 

1


  • Jan 31, 2022 11:51 AM UTC

  • Jan 31, 2022 12:47 PM UTC

Hi, Ino Steinke

 

The same thing is happening...

If you find a solution, please let me know.

 


  • Jan 31, 2022 12:48 PM UTC

Hello,

 

Could you please attach screenshot from the last calculation? I've done it in PQL and everything seems to be fine.

It was done in SQL?

 

Calculation 

Best Regards,

Mateusz Dudek

Hello.

Thank you for answering.

I uploaded a screenshot.

 

It was done in SQL?

>>>Yes

 

What's wrong?

18


  • Feb 11, 2022 8:09 PM UTC

Hello @ryotaro.manab 

 

sorry for late reply - it's probably underlying grouping problem.

F.e. if one sum is taking amounts from document level, and the second from document item level aditional calulation steps can be done in the background. I would using numbers having same "level" of data, it can be done by using domain table or PU functions. If mixed "levels" of data are used (SUM on document level, divided by SUM of item level) results can be strange as one of SUM statement will be automatically grouped again.

 

Additional note: screenshot seems to be PQL editor, so issue was located in the front-end. It's important because it affect the causes of the problem and available ways of solving it.

 

Hope that helps :)

 

Best Regards,

Mateusz Dudek