mirror of
https://gitee.com/wangbin579/cetus.git
synced 2024-12-02 03:47:41 +08:00
Fix order by related problems
This commit is contained in:
parent
9c72a1a87d
commit
c7cc0278b1
@ -1846,9 +1846,8 @@ heap_adjust(heap_type *heap, int s, int m, int *compare_failed)
|
||||
j++;
|
||||
} else if (!heap->element[j + 1]->is_over) {
|
||||
if (!heap->element[j]->refreshed && !heap->element[j + 1]->refreshed) {
|
||||
if (!heap->element[j]->is_prior_to) {
|
||||
if (heap->element[j]->is_prior_to == -1) {
|
||||
j++;
|
||||
} else {
|
||||
}
|
||||
} else {
|
||||
is_dup = 0;
|
||||
@ -1857,7 +1856,7 @@ heap_adjust(heap_type *heap, int s, int m, int *compare_failed)
|
||||
heap->element[j + 1]->record->data, &(heap->order_para),
|
||||
heap->element[j]->index, heap->element[j + 1]->index, &is_dup, compare_failed)) {
|
||||
j++;
|
||||
heap->element[j]->is_prior_to = 0;
|
||||
heap->element[j]->is_prior_to = -1;
|
||||
|
||||
} else {
|
||||
if (is_dup) {
|
||||
|
@ -54,11 +54,11 @@ typedef struct ORDER_BY {
|
||||
typedef struct {
|
||||
GList *record;
|
||||
int index;
|
||||
int is_prior_to;
|
||||
unsigned int is_over:1;
|
||||
unsigned int is_err:1;
|
||||
unsigned int refreshed:1;
|
||||
unsigned int is_dup:1;
|
||||
unsigned int is_prior_to:1;
|
||||
} heap_element;
|
||||
|
||||
typedef struct order_by_para_s {
|
||||
|
Loading…
Reference in New Issue
Block a user