{"id":520,"date":"2025-01-08T06:20:50","date_gmt":"2025-01-08T06:20:50","guid":{"rendered":"https:\/\/basicwebsitesolutions.com\/blog\/?p=520"},"modified":"2025-01-08T06:20:51","modified_gmt":"2025-01-08T06:20:51","slug":"interbase-how-to-manually-round-calculate-3rd-decimal-solved","status":"publish","type":"post","link":"https:\/\/basicwebsitesolutions.com\/blog\/2025\/01\/08\/interbase-how-to-manually-round-calculate-3rd-decimal-solved\/","title":{"rendered":"Interbase &#8211; How to manually round calculate 3rd decimal [SOLVED]"},"content":{"rendered":"\n<p>I have seen a few computations done in interbase and a lot of them have trailing decimals after them and if we want to round them manually, this is what I have come up with.<\/p>\n\n\n\n<p>Suggestions and alternative solutions are always welcome. I am using a few variables so I can see the results of the computation as they unravel.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/* 889.125 *\/\nVINT1 = (PANNUAL_TAX * 100);\nVAMT1 = (VINT1 \/ 100);\n\nVINT2 = (PANNUAL_TAX - VAMT1) * 1000;\nVAMT2 = VINT2;\n\nIF (VAMT2 >= 50) THEN\n     VAMT3 = VAMT1 + 0.01;\nELSE VAMT3 = VAMT1;\n\nPANNUAL_TAX = VAMT3;\n<\/code><\/pre>\n\n\n\n<p>The PANNUAL_TAX is the variable that holds the 2 decimal result.<\/p>\n\n\n\n<p>Enjoy,<\/p>\n\n\n\n<p>Coffee Cup<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have seen a few computations done in interbase and a lot of them have trailing decimals after them and if we want to round them manually, this is what I have come up with. Suggestions and alternative solutions are always welcome. I am using a few variables so I can see the results of &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/basicwebsitesolutions.com\/blog\/2025\/01\/08\/interbase-how-to-manually-round-calculate-3rd-decimal-solved\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Interbase &#8211; How to manually round calculate 3rd decimal [SOLVED]&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,3,2],"tags":[348,36,37,347,88,87],"class_list":["post-520","post","type-post","status-publish","format-standard","hentry","category-day-to-day-life","category-delphi-and-interbase","category-windows-and-beyond","tag-2-decimals","tag-delphi","tag-interbase","tag-rounding","tag-win10","tag-windows-10"],"_links":{"self":[{"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/posts\/520","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=520"}],"version-history":[{"count":1,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/posts\/520\/revisions"}],"predecessor-version":[{"id":521,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/posts\/520\/revisions\/521"}],"wp:attachment":[{"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=520"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=520"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/basicwebsitesolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=520"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}