[ 
https://issues.apache.org/jira/browse/KYLIN-2608?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

hongbin ma resolved KYLIN-2608.
-------------------------------
       Resolution: Fixed
    Fix Version/s: v2.1.0

> Bubble sort bug in JoinDesc
> ---------------------------
>
>                 Key: KYLIN-2608
>                 URL: https://issues.apache.org/jira/browse/KYLIN-2608
>             Project: Kylin
>          Issue Type: Bug
>            Reporter: hongbin ma
>            Assignee: hongbin ma
>             Fix For: v2.1.0
>
>
> The bug may cause model unable to match when PK/FK contains multiple columns
> {code}
>          int n = foreignKey.length;
>          for (int i = 0; i < n - 1 && cont; i++) {
>              cont = false;
> -            for (int j = i; j < n - 1; j++) {
> +            for (int j = 0; j < n - 1 - i; j++) {
>                  int jj = j + 1;
>                  if (foreignKey[j].compareTo(foreignKey[jj]) > 0) {
>                      swap(foreignKey, j, jj);
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to