小数点以下約 13 桁を超える長い小数文字列は、ブラウザで操作するときに精度が失われたり、丸められたりする可能性があります。このような数値の精度損失はブラウザによって処理方法が異なるため、小数点の丸めにばらつきが生じます。この現象は、Web ブラウザの JavaScript Number オブジェクトの制限です。
この JavaScript の動作は、Salesforce の外部のブラウザ内で直接確認できます。たとえば、Chrome では次のようにします。
開発者コンソールで数値項目に値を入力したときにも、これと同じ丸めが発生することがあります。
この動作は JavaScript の数値処理によるものであり、Salesforce では制御できません。API 経由で長い小数文字列を入力した場合、UI でこれらの項目を操作するユーザには JavaScript によって丸められた数値が表示される可能性があります。UI でそのようなレコードを保存すると、丸められた値がデータベースに保存されます。データベースの値が変更されないことを要件とする Salesforce 検証がある場合、この丸めは変更とみなされ、検証がトリガされます。
API を使用すると、項目で許可されている小数点以下の最大桁数よりも高い精度の数値を保存できます。詳細は、「数値データ型の項目に定義よりも多い小数点以下の桁数を保存できる」を参照してください。
000394530

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.