Am Thu, Jun 15, 2023 at 12:58:55AM +0300 schrieb Ruslan Zakirov:
e.g.
> https://mariadb.com/kb/en/why-is-order-by-in-a-from-subquery-ignored/
...
> My goal was to find a small dataset that demonstrates this ordering
> mismatch.
I attempted to think it through whether it is even *possible*
to f
On Wed, Jun 14, 2023 at 3:50 PM Karsten Hilbert
wrote:
> IOW neither is help to be expected on this list nor can any
> testing (on PG) help with anything to be expected on MySQL ?
>
Don't expect any help on mysql part.
As to the question: since the outer query does not have an
> ORDER BY it can
Am Wed, Jun 14, 2023 at 01:03:06PM +0300 schrieb Ruslan Zakirov:
> > This is a too complex query to build a test on. Tried simpler scenarios
> > and failed.
> >
>
> First of all I want to apologize. We work with multiple RDBMS systems. This
> particular user is using mysql.
...
> Anyway, yesterday
On 6/14/23 05:03, Ruslan Zakirov wrote:
[snip]
Anyway, yesterday I tried my simplified case on Pg latest, Pg 11 and on
mysql latest. Had no luck. Either my test case is too simple or I can not
find the correct distribution of data between two tables.
This is when you need a prod copy...
--
Bo
On Tue, Jun 13, 2023 at 8:55 PM Ruslan Zakirov
wrote:
> On Tue, Jun 13, 2023 at 6:06 PM Tom Lane wrote:
>
>> Ruslan Zakirov writes:
>> > I know how to fix the problem and I know that ORDER BY should be in the
>> > outermost select.
>>
>> > However, I want to write a test case that shows that th
On Tue, Jun 13, 2023 at 10:55 AM Ruslan Zakirov
wrote:
> Thanks for replying. Maybe I'm just wrong in my assumption. A user reports
> incorrect order in the following query:
>
> SELECT main.*, COUNT(main.id) OVER() AS search_builder_count_all FROM (
> SELECT DISTINCT main.* FROM Tickets main
>
On Tue, Jun 13, 2023 at 6:06 PM Tom Lane wrote:
> Ruslan Zakirov writes:
> > I know how to fix the problem and I know that ORDER BY should be in the
> > outermost select.
>
> > However, I want to write a test case that shows that the old code is
> wrong,
> > but can not create
> > minimal set of
Ruslan Zakirov writes:
> I know how to fix the problem and I know that ORDER BY should be in the
> outermost select.
> However, I want to write a test case that shows that the old code is wrong,
> but can not create
> minimal set of tables to reproduce it. With this I'm looking for help.
The ORD
On Tue, Jun 13, 2023 at 1:26 PM Thomas Kellerer wrote:
> Ruslan Zakirov schrieb am 13.06.2023 um 09:49:
> > For example I have a query:
> >
> > SELECT main.*, count(*) OVER () FROM (SELECT DISTINCT ... ORDER BY X)
> > main;
> >
> > So the `ORDER BY` clause ended up in a subquery. Most of the time
Ruslan Zakirov schrieb am 13.06.2023 um 09:49:
> For example I have a query:
>
> SELECT main.*, count(*) OVER () FROM (SELECT DISTINCT ... ORDER BY X)
> main;
>
> So the `ORDER BY` clause ended up in a subquery. Most of the time
> ordering works until it doesn't.
>
> Can you help me create a set of
Hello,
For example I have a query:
SELECT main.*, count(*) OVER () FROM (SELECT DISTINCT ... ORDER BY X) main;
So the `ORDER BY` clause ended up in a subquery. Most of the time ordering
works until it doesn't.
Can you help me create a set of test tables with some data to reproduce
this problem
11 matches
Mail list logo