Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lC5uv-00047N-DA for pgsql-general@arkaria.postgresql.org; Tue, 16 Feb 2021 19:21:49 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lC5ut-0006tP-CG for pgsql-general@arkaria.postgresql.org; Tue, 16 Feb 2021 19:21:47 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lC5us-0006ne-TN for pgsql-general@lists.postgresql.org; Tue, 16 Feb 2021 19:21:47 +0000 Received: from sonic310-21.consmr.mail.gq1.yahoo.com ([98.137.69.147]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1lC5uq-00046P-2S for pgsql-general@lists.postgresql.org; Tue, 16 Feb 2021 19:21:46 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1613503301; bh=sXdoG1NKe5jKjtf/mZ6BJWhWdSOT2bBZnbbsCTZKc14=; h=From:Subject:Date:In-Reply-To:Cc:To:References:From:Subject:Reply-To; b=G6I9wBxZMzABIIZ02Kd/yosTZA1NzZQXk7VEoX3wLRV5brTJBmU26FE/xl/dy5o1pQFDJZ6ybLzB71tjF9G7mAbwJC2RBxh6PYCmOCZvnnzq1wjqiSx6ICrgBq9I4lYjF2HTl59+nmej7Uy35h0usp1gGPMG5qktBhHFr+XKBvhksoxkwudoN93E34U3qLi1ADLejGK7y83g14aupIoy/je+vN4FqWN27ld1OQvW2LTMA8WotDu8HQPer2QeWu6tNxbVjFoqSw1pR0Z4Zt/rLz/EHJWe86BXqpEIYZykDzyYx+2Ke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Zl45PMMTaWlYWzX0NHbXG5d_PE0ucSqPHLXrZqnt7RnWnUQevAfULfZh0FiANGWql51SKU 87GpA6sdx5JOmszr6rmJF3wyYvT.nPtLuMBD3CVHzMl_FcDr9fwJKls4lpH5_o7tv9qxzORWKR4r NHZIWpkXpZ6JT0aKLNK.ui5XhqmAUjmjxugQHjS0CiCA9aB9X.jBv6ltvzjNL_UhvLkZEwheEPwN QJHxwd9R4jrleQfQn2aOmhz22ARe5Qrh8Mq8MaAHup96kOPY0KjbbN.6ZiSgSDruprjYEU590DqS e5tIH8lJs2gecQjuHLx0G_IcZfQrM40hw8dJcJZS_NgfFMNlDEgMUtPTqBgMwmM.mnj6KdqYS8C5 mVkFDFfA6_h7vBbAnsWYXf9UXdkA_lhYYva9lKxXGVFckvRwPizts.rLsRRwN5q1LiGD8wcrf9_c T5IGCIGTPvIOSv1HcbixoMb4ir_HCsbIqUfrHeg7twQ8V.2kTiNRGoH_mMbiBrBfEC53YDNv2B8h UphlncQmeYM5MyXnGGIAvOYo5naD7fYkr74jW.OzRMW.eX7lpJbLMBEbSD8u3y2w1GaM8j5sk8vt 197cKJstNeSBtv8d2Y0xCsUcVcWyUO5r_.D3sNLPE6XUzFNmBUkxERQ6RrxsJuUx2cF4b60y9LJR ttsHWbq.zssPvID0RWnP4VfFKjaxDqTNb_5rJEv7pdtta2zwYtXBf_EVV4hHgyol.grtI6J3LtxW C9R6KOReGYTBk_X.GTpJbEXepJ2unYxZUYmwACQCx6Acc9OqMMe3e_rfEutRHCCTI2e7QE56LlJb RUyRSEMk3blzU6a9SuDzWakWVhWgWd3F5qRU.ESgfMpG8ZLO.xbF0jOAtYmMp49GDLOfIS.GE7Hu 9gprqcYVj_ZAnuGRPKm.Cr166nWeGNl6nwA.km1e605JYEATeiTc9HNYlaw-- X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic310.consmr.mail.gq1.yahoo.com with HTTP; Tue, 16 Feb 2021 19:21:41 +0000 Received: by smtp419.mail.bf1.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID 8eb8cd2dca03f5c39b1de5addd2f0701; Tue, 16 Feb 2021 19:21:36 +0000 (UTC) From: Dan Nessett Message-Id: <1D84F613-D7C7-4EC0-95EF-4FBB56D0F160@yahoo.com> Content-Type: multipart/alternative; boundary="Apple-Mail=_18812252-3A27-43B0-8006-E4DD545BBF57" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.17\)) Subject: Re: Order by not working Date: Tue, 16 Feb 2021 12:21:33 -0700 In-Reply-To: Cc: pgsql-general@lists.postgresql.org To: Ron References: <8D049DD1-DC0D-498B-B7C1-773C4FB82B22.ref@yahoo.com> <8D049DD1-DC0D-498B-B7C1-773C4FB82B22@yahoo.com> <39D5CE9D-B64F-420F-8260-88B6CD50DED3@datylon.com> <2DD24450-CD97-4212-89A9-3640A07B1E0C@yahoo.com> X-Mailer: Apple Mail (2.3445.104.17) Content-Length: 4615 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --Apple-Mail=_18812252-3A27-43B0-8006-E4DD545BBF57 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Thanks, Dan > On Feb 16, 2021, at 12:11 PM, Ron wrote: >=20 > What would you tell pgadmin? "Order this particular query -- out of = all the billion queries I might write -- in this particular manner?" >=20 > No, that's not how things work. Just add an ORDER BY when you query = the table. >=20 > On 2/16/21 12:48 PM, Dan Nessett wrote: >> Thanks Peter. The listing of the result is from pg-admin 4.30 using = view/edit data applied to the household_data table. In the past this has = always returned the table contents in the ORDR BY sort order. Do I need = to specify some preference in pg_admin to guarantee this? >>=20 >> Dan >>=20 >>> On Feb 16, 2021, at 11:34 AM, Peter Coppens = wrote: >>>=20 >>> Not sure how you select the household >>>=20 >>>> The result is (only the first column is shown): >>>>=20 >>>> household_name >>>>=20 >>>> "Garcia" >>>> "Armstrong" >>>> "Armstrong" >>>> "Bauer" >>>> "Bauer" >>>> "Berst" >>>> "Berst" >>>> "Minch (xxxx)" >>>> "Berst" >>>> =E2=80=9CBesel=E2=80=9D >>>=20 >>> but unless you select from the resulting table using again an order = by, the rows will be returned in an undetermined order. Such is the = nature of the relational model - there is no order you can rely on when = selecting, unless you specify it >>>=20 >>> Hth, >>>=20 >>> Peter >>>=20 >>=20 >>=20 >=20 > --=20 > Angular momentum makes the world go 'round. --Apple-Mail=_18812252-3A27-43B0-8006-E4DD545BBF57 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 Thanks,

Dan

On Feb 16, 2021, at 12:11 PM, Ron <ronljohnsonjr@gmail.com> wrote:

=20 =20
What would you tell pgadmin?  "Order this particular query -- out of all the billion queries I might write -- in this particular manner?"

No, that's not how things work.  Just add an ORDER BY when you = query the table.

On 2/16/21 12:48 PM, Dan Nessett = wrote:
Thanks Peter. The listing =
of the result is from pg-admin 4.30 using view/edit data applied to the =
household_data table. In the past this has always returned the table =
contents in the ORDR BY sort order. Do I need to specify some preference =
in pg_admin to guarantee this?

Dan

On Feb 16, 2021, at 11:34 =
AM, Peter Coppens <peter.coppens@datylon.com>=
; wrote:

Not sure how you select the household

The result is (only the =
first column is shown):

household_name

"Garcia"
"Armstrong"
"Armstrong"
"Bauer"
"Bauer"
"Berst"
"Berst"
"Minch (xxxx)"
"Berst"
=E2=80=9CBesel=E2=80=9D
but unless you select from the resulting table using again an order by, =
the rows will be returned in an undetermined order. Such is the nature =
of the relational model - there is no order you can rely on when =
selecting, unless you specify it

Hth,

Peter



--
Angular momentum makes the world go 'round.

= --Apple-Mail=_18812252-3A27-43B0-8006-E4DD545BBF57--