Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.php > #16638

Re: Keeping search results random, but same in MySQL

Path csiph.com!2.eu.feeder.erje.net!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.kamp.net!newsfeed.kamp.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From Arno Welzel <usenet@arnowelzel.de>
Newsgroups comp.lang.php
Subject Re: Keeping search results random, but same in MySQL
Date Tue, 15 Mar 2016 09:02:43 +0100
Lines 18
Message-ID <56E7C1A3.1070005@arnowelzel.de> (permalink)
References <826cbc6d-9807-496c-9cff-111c57890f06@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=windows-1252
Content-Transfer-Encoding 7bit
X-Trace individual.net I8lp8v4HgKVOrW8qaWfgdQe3RbCOE/fnB1LLDxtxbOpH6+7Y7U
Cancel-Lock sha1:ZdNhMCMXDNujfA1UHfAKh5uKwpQ=
In-Reply-To <826cbc6d-9807-496c-9cff-111c57890f06@googlegroups.com>
Xref csiph.com comp.lang.php:16638

Show key headers only | View raw


bit-naughty@hotmail.com schrieb am 2016-03-15 um 06:29:

> ....if I have a table on which I'm doing a MySQL query, for which I
> want the search results in a *random* order, but the *same order
> everytime I do the search* (i.e. say it's a "SELECT name FROM table
> WHERE thingbought='oranges' "; ), what do I do? Does that make sense?

If you want sorted results, you have to sort them, usually by using
ORDER BY in your query.

But was has this to do with PHP?


-- 
Arno Welzel
http://arnowelzel.de
http://de-rec-fahrrad.de
http://fahrradzukunft.de

Back to comp.lang.php | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Keeping search results random, but same in MySQL bit-naughty@hotmail.com - 2016-03-14 22:29 -0700
  Re: Keeping search results random, but same in MySQL Geoff Muldoon <geoff.muldoon@trap.gmail.com> - 2016-03-15 17:16 +1100
    Re: Keeping search results random, but same in MySQL Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2016-03-15 18:58 +0100
      Re: Keeping search results random, but same in MySQL Jerry Stuckle <jstucklex@attglobal.net> - 2016-03-15 14:40 -0400
      Re: Keeping search results random, but same in MySQL Geoff Muldoon <geoff.muldoon@trap.gmail.com> - 2016-03-16 13:56 +1100
        Re: Keeping search results random, but same in MySQL Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2016-03-16 19:56 +0100
  Re: Keeping search results random, but same in MySQL gordonb.paboe@burditt.org (Gordon Burditt) - 2016-03-15 01:19 -0500
  Re: Keeping search results random, but same in MySQL Arno Welzel <usenet@arnowelzel.de> - 2016-03-15 09:02 +0100
  Re: Keeping search results random, but same in MySQL Lew Pitcher <lew.pitcher@digitalfreehold.ca> - 2016-03-15 13:03 -0400
    Re: Keeping search results random, but same in MySQL bit-naughty@hotmail.com - 2016-03-16 10:26 -0700

csiph-web