Order By does not properly work when using round robin

Bug #929109 reported by Jim Mlodgenski
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Stado
Invalid
Undecided
Unassigned

Bug Description

I tried an order by query on one table that is partitioned by a single column and a second table that is "round robin on all" - The order of the rows returned seems to be broken (incorrect) when the table is defined as "round robin on all".

Please see following sql for an example:

GridSQL -> create table p1 (f1 int, f2 varchar(10)) round robin on all;
OK

GridSQL -> create table p2 (f1 int, f2 varchar(10)) partitioning key f1 on all;
OK

GridSQL -> insert into p1 values (10, 'abcd');
insert into p1 values (10, 'defg');
insert into p1 values (10, 'Cbcd');
insert into p1 values (10, 'Hefg');

insert into p2 values (10, 'abcd');
insert into p2 values (10, 'defg');
insert into p2 values (10, 'Cbcd');
insert into p2 values (10, 'Hefg');
1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> GridSQL -> GridSQL -> 1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> 1 row(s) affected

GridSQL -> commit;

# Query from table that is "round robin on all" returns wrong results - (i.e. data is fine but presented in the wrong order)

GridSQL -> select * from p1 order by f2 desc;
+-----------+
| f1 | f2 |
+-----------+
| 10 | defg |
| 10 | Hefg |
| 10 | abcd |
| 10 | Cbcd |
+-----------+
4 row(s).

# Query from table partitioned by f2 returns correct results

GridSQL -> select * from p2 order by f2 desc;
+-----------+
| f1 | f2 |
+-----------+
| 10 | defg |
| 10 | abcd |
| 10 | Hefg |
| 10 | Cbcd |
+-----------+
4 row(s).

Revision history for this message
Andrei Martsinchyk (andrei-martsinchyk) wrote :

This is a configuration problem.
Backend is configured to sort strings as case sensitive, while Stado is configured to sort strings as case insensitive (default).
Stado engine expects backend is returning data properly sorted.
To fix the problem add
xdb.sort.case.sensitive=true
to the Stado configuration file.

Changed in stado:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.