Re: Updating record drops it to the bottom - Mailing list pgsql-general

From Doug McNaught
Subject Re: Updating record drops it to the bottom
Date
Msg-id m38yzgfjet.fsf@varsoon.wireboard.com
Whole thread Raw
In response to Updating record drops it to the bottom  ("Aurangzeb M. Agha" <aagha@bigfoot.com>)
List pgsql-general
"Aurangzeb M. Agha" <aagha@bigfoot.com> writes:

> I've noticed that whenever I update a record in the table and do a select
> * to see my change, that the updated racord has dropped to the bottom of
> the table.
>
> Is there either a) a (simple) way to keep this from happening or b)
> putting the record back where it "belongs" after an update.

Postgres (and most other SQL databases) makes no guarantee about the
order of results from a SELECT unless you use an ORDER BY clause.  So
put ORDER BY in your query if you care about the display order.

-Doug

pgsql-general by date:

Previous
From: Larry Rosenman
Date:
Subject: Re: Updating record drops it to the bottom
Next
From: "Henshall, Stuart - Design & Print"
Date:
Subject: Re: Updating record drops it to the bottom