Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved.
Terms
of Use |
Trademarks
Article ID: 821421 - Last Review: August 13, 2003 - Revision: 1.3
PRB: Data Is Not Correct, or Is Not as Precise as Expected, When You Use Numeric Functoids in BizTalk Mapper
When you use some BizTalk Mapper numeric functoids to calculate noninteger values, your
results may not be correct or they may not be as precise as expected. For example, if
you multiply
20815.2000 by
1.00, you may receive
208152000 for the result instead of
20815.2.
This behavior may occur if the Default System Locale on your computer running BizTalk Server (or on the computer of a user who logs on) is set to a Regional Locale
that uses a different decimal separator character from the one that the data uses in the document that you are processing.
To work around this behavior, do one of the following:
- Change the Default System Locale to a Regional Locale that
uses the same decimal separator character as your data. Also, verify that every user who
logs on locally to the system uses a Regional Locale that uses the same
character for the decimal separator in the Numbers format setting and in the Currency format setting.
-or- - Insert a Microsoft Visual Basic Scripting Edition (VBScript)
functoid in your BizTalk Mapper to change the locale for calculations
that are performed in the map. The following sample code temporarily changes the system
locale to US English:
SetLocale("us-en")
Function MyFunction0( )
MyFunction0 = ""
End Function
This functoid uses a call to the VBScript SetLocale function, and
then passes in the required Locale ID value. This action forces the correct locale setting
for the duration of the BizTalk Mapper execution.
This behavior is by design.
When an interactive user logs on, the settings on the user's computer can affect the
Locale ID value, and the
Locale ID affects how date, time, and currency values are formatted.
Microsoft recommends that you explicitly set the
Locale ID value by using a BizTalk Mapper functoid. For more information,
see the "Resolution" section.
APPLIES TO
- Microsoft BizTalk Server 2002 Standard Edition
Community Feedback System
Very often, it takes hours to solve a problem. Very often, you've looked high
and low, and have tried a lot of solutions. When you finally found it, chances
are, it was because someone else helped you. Here's your chance to give back.
Use our community feedback tool to let others know what worked for you and what
didn't.
Please also understand that the community feedback system is not warranted to be
correct, it's simply a system that we've built to let people try and help each
other. If something in a feedback response doesn't make sense to you, or you're
not comfortable making changes that the feedback talks about (like registry
edits), please consult a professional.
Thank you for using kbAlertz.com Feedback System.
-- Scott Cate