This question has been asked so many, many, many times that it has become rather tedious for us to keep explaining it over and over again.
Please do a search here on the Forum and the CodeBase, because you are guaranteed to find the answer repeated several times.
EDIT: Looks like @whroeder1 was generous enough to answer your query without you needing to trouble yourself with searching for it!
I searched many, many, many times this topic and I did many, many, many attempts. But I didn't reached what I was looking for. So I asked here.
Really thanks for your explanation. I use the same way to calculate orders lots, but now I learned how to normalize lots. And now it seems works fine.