[jira] [Commented] (OFBIZ-10298) Fluent API Bug in getFieldList()

2020-02-25 Thread ASF subversion and git services (Jira)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17044800#comment-17044800
 ] 

ASF subversion and git services commented on OFBIZ-10298:
-

Commit 8afb711ef31751e36cc6155dd6bbaf21cacb6f3e in ofbiz-framework's branch 
refs/heads/trunk from Michael Brohl
[ https://gitbox.apache.org/repos/asf?p=ofbiz-framework.git;h=8afb711 ]

Fixed: Fluent API Bug in getFieldList().

(OFBIZ-10298)

Thanks Benjamin Jugl for reporting and providing the patch.

> Fluent API Bug in getFieldList()
> 
>
> Key: OFBIZ-10298
> URL: https://issues.apache.org/jira/browse/OFBIZ-10298
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework
>Affects Versions: Release Branch 18.12, Release Branch 17.12, Trunk
>Reporter: Benjamin Jugl
>Assignee: Michael Brohl
>Priority: Minor
> Attachments: OFBIZ-10298_fluent_API_Bug.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_distinct_to_primitive.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_getFieldList_Fix.patch
>
>
> In EntityQuery the method getFieldList() uses the class variable {{distinct}} 
> to decide if the list of genericValues should be stored in a set to eliminate 
> duplicate values. This variable is set by the function distinct() and 
> normally it should only be used for the sql statement. But here the flag gets 
> mistreated since, if the list of values was ordered because of orderBy(), the 
> order of values gets lost by putting them into a set. To summarize, the 
> following statement:
> {{orderBy("...").dinstinct().getFieldLlist("...");}}
> does not produce an ordered list.
> Replacing the HashSet by a LinkedHashSet fixes this issue.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (OFBIZ-10298) Fluent API Bug in getFieldList()

2020-02-25 Thread ASF subversion and git services (Jira)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17044803#comment-17044803
 ] 

ASF subversion and git services commented on OFBIZ-10298:
-

Commit 651231d04116ef029a59375798d33e97031b15c3 in ofbiz-framework's branch 
refs/heads/release17.12 from Michael Brohl
[ https://gitbox.apache.org/repos/asf?p=ofbiz-framework.git;h=651231d ]

Fixed: Fluent API Bug in getFieldList().

(OFBIZ-10298)

Thanks Benjamin Jugl for reporting and providing the patch.

> Fluent API Bug in getFieldList()
> 
>
> Key: OFBIZ-10298
> URL: https://issues.apache.org/jira/browse/OFBIZ-10298
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework
>Affects Versions: Release Branch 18.12, Release Branch 17.12, Trunk
>Reporter: Benjamin Jugl
>Assignee: Michael Brohl
>Priority: Minor
> Attachments: OFBIZ-10298_fluent_API_Bug.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_distinct_to_primitive.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_getFieldList_Fix.patch
>
>
> In EntityQuery the method getFieldList() uses the class variable {{distinct}} 
> to decide if the list of genericValues should be stored in a set to eliminate 
> duplicate values. This variable is set by the function distinct() and 
> normally it should only be used for the sql statement. But here the flag gets 
> mistreated since, if the list of values was ordered because of orderBy(), the 
> order of values gets lost by putting them into a set. To summarize, the 
> following statement:
> {{orderBy("...").dinstinct().getFieldLlist("...");}}
> does not produce an ordered list.
> Replacing the HashSet by a LinkedHashSet fixes this issue.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (OFBIZ-10298) Fluent API Bug in getFieldList()

2020-02-25 Thread ASF subversion and git services (Jira)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17044801#comment-17044801
 ] 

ASF subversion and git services commented on OFBIZ-10298:
-

Commit f4d96deeca183f321bb285a4c4eb11ad052e7120 in ofbiz-framework's branch 
refs/heads/release18.12 from Michael Brohl
[ https://gitbox.apache.org/repos/asf?p=ofbiz-framework.git;h=f4d96de ]

Fixed: Fluent API Bug in getFieldList().

(OFBIZ-10298)

Thanks Benjamin Jugl for reporting and providing the patch.

> Fluent API Bug in getFieldList()
> 
>
> Key: OFBIZ-10298
> URL: https://issues.apache.org/jira/browse/OFBIZ-10298
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework
>Affects Versions: Release Branch 18.12, Release Branch 17.12, Trunk
>Reporter: Benjamin Jugl
>Assignee: Michael Brohl
>Priority: Minor
> Attachments: OFBIZ-10298_fluent_API_Bug.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_distinct_to_primitive.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_getFieldList_Fix.patch
>
>
> In EntityQuery the method getFieldList() uses the class variable {{distinct}} 
> to decide if the list of genericValues should be stored in a set to eliminate 
> duplicate values. This variable is set by the function distinct() and 
> normally it should only be used for the sql statement. But here the flag gets 
> mistreated since, if the list of values was ordered because of orderBy(), the 
> order of values gets lost by putting them into a set. To summarize, the 
> following statement:
> {{orderBy("...").dinstinct().getFieldLlist("...");}}
> does not produce an ordered list.
> Replacing the HashSet by a LinkedHashSet fixes this issue.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (OFBIZ-10298) Fluent API Bug in getFieldList()

2018-12-12 Thread Benjamin Jugl (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10298?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16718953#comment-16718953
 ] 

Benjamin Jugl commented on OFBIZ-10298:
---

The patches also provides some improvements to the code, like removing 
unnecessary autoboxing.

> Fluent API Bug in getFieldList()
> 
>
> Key: OFBIZ-10298
> URL: https://issues.apache.org/jira/browse/OFBIZ-10298
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework
>Affects Versions: Trunk
>Reporter: Benjamin Jugl
>Priority: Minor
> Attachments: 
> OFBIZ-10298_org.apache.ofbiz.entity.util_distinct_to_primitive.patch, 
> OFBIZ-10298_org.apache.ofbiz.entity.util_getFieldList_Fix.patch
>
>
> In EntityQuery the method getFieldList() uses the class variable {{distinct}} 
> to decide if the list of genericValues should be stored in a set to eliminate 
> duplicate values. This variable is set by the function distinct() and 
> normally it should only be used for the sql statement. But here the flag gets 
> mistreated since, if the list of values was ordered because of orderBy(), the 
> order of values gets lost by putting them into a set. To summarize, the 
> following statement:
> {{orderBy("...").dinstinct().getFieldLlist("...");}}
> does not produce an ordered list.
> Replacing the HashSet by a LinkedHashSet fixes this issue.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)