[jira] Created: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
-----------------------------------------------------------------------------------

                 Key: OFBIZ-136
                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
             Project: OFBiz (The Open for Business Project)
          Issue Type: Bug
          Components: framework
    Affects Versions: SVN trunk
            Reporter: Si Chen
             Fix For: SVN trunk


This thread on sourceforge.net for opentaps will give you some background:
http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771

But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:

        <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            

always returns false if the locale is set to fr_FR.UTF-8 as in the following:
-Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8

in your startofbiz.sh

or equivalent in windows

I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.

To solve the problem in the meantime, you can use
-Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-136?page=all ]

Si Chen updated OFBIZ-136:
--------------------------

    Attachment: minilang-if-compare-locale.png

I tried to post a very simple acctg trans: one entry debit 1.0 USD, one entry credit 1.0 USD.  It failed because minilang thinks 1.0 - 1.0  <> 0.0 for this locale and language combination (fr_FR.UTF-8)

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-136?page=comments#action_12425900 ]
           
Si Chen commented on OFBIZ-136:
-------------------------------

Switching it back to English fixed it.

You can see it here:
https://demo.opensourcestrategies.com:8446/financials/control/viewAcctgTrans?acctgTransId=10000

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-136?page=comments#action_12426135 ]
           
David E. Jones commented on OFBIZ-136:
--------------------------------------

This should be fixed in SVN rev 429249. For details see the comments on that commit.

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-136?page=comments#action_12426454 ]
           
David E. Jones commented on OFBIZ-136:
--------------------------------------

Could someone test this to see if that change fixed the problem? I was looking into OFBIZ-114 and it may be that the problem showed up there as well.

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
    [ http://issues.apache.org/jira/browse/OFBIZ-136?page=comments#action_12426734 ]
           
Si Chen commented on OFBIZ-136:
-------------------------------

It worked for me now, repeating the steps above.  Thanks for fixing it so quickly David.

Si

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-136) mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)
     [ http://issues.apache.org/jira/browse/OFBIZ-136?page=all ]

David E. Jones closed OFBIZ-136.
--------------------------------

    Resolution: Fixed
      Assignee: David E. Jones

This should be pretty well fixed now.

> mininlang if-compare does not work correctly in some locales (fr_FR.UTF-8) probably
> -----------------------------------------------------------------------------------
>
>                 Key: OFBIZ-136
>                 URL: http://issues.apache.org/jira/browse/OFBIZ-136
>             Project: OFBiz (The Open for Business Project)
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Si Chen
>         Assigned To: David E. Jones
>             Fix For: SVN trunk
>
>         Attachments: minilang-if-compare-locale.png
>
>
> This thread on sourceforge.net for opentaps will give you some background:
> http://sourceforge.net/forum/forum.php?thread_id=1545546&forum_id=487771
> But basically, it appears that for certain locales, using if-compare on numbers in minilang does not work.  In applications/accounting/script/org/ofbiz/accounting/ledger/AcctgTransServices.xml:
>         <if-compare field-name="trialBalanceResultMap.debitCreditDifference" operator="greater-equals" value="0.01" type="Double">            
> always returns false if the locale is set to fr_FR.UTF-8 as in the following:
> -Duser.language=fr -Duser.region=FR -Dfile.encoding=UTF-8
> in your startofbiz.sh
> or equivalent in windows
> I think this is a problem with the org.ofbiz.base.ObjectType's typecasting.
> To solve the problem in the meantime, you can use
> -Duser.language=en -Duser.region=US

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira