Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #10396
| Date | 2013-08-04 20:20 +0200 |
|---|---|
| From | Luuk <luuk@invalid.lan> |
| Newsgroups | comp.lang.php, alt.php |
| Subject | Re: sql order but move some rows bottom |
| References | (4 earlier) <19m253q4wpnqg.3aexf4o8h0ae$.dlg@40tude.net> <1l02da-q4u.ln1@luuk.invalid.lan> <cilihgucmwnw.1jmbvfrj3djn8.dlg@40tude.net> <q3g2da-vl1.ln1@luuk.invalid.lan> <esac9bff8sko.tmz61t9wiv4.dlg@40tude.net> |
| Message-ID | <2li2da-282.ln1@luuk.invalid.lan> (permalink) |
Cross-posted to 2 groups.
On 04-08-2013 19:53, nawfer wrote: > Il Sun, 04 Aug 2013 19:37:32 +0200, Luuk ha scritto: > >> On 04-08-2013 17:49, nawfer wrote: >>>> y before 100: >>>> ORDER BY >>>> (CASE WHEN column2 = 100 THEN 2 ELSE 0 END + CASE WHEN column3='Y' THEN >>>> 1 ELSE 0 END) ASC, column1 ASC, column2 ASC >>> >>> small curiosity >>> the above code respect at a simple order >>> >>> ORDER BY column1 ASC, column2 ASC >>> >>> >>> change the performance (example - 5%)or is insignificant the difference? >>> >> >> >> Sorry, my English is not good enough to understand what you mean ..... >> Could you rephrase the question? > > I ask if the code you post me for does order taht is more complex than a > simple order by make slow the query ; is more slow of 5% 10% or more? > Yes, its slower, but i dont not know how much slower. With a couple of records you will not notice the difference, but with 'a lot of records'* you might notice some delay ;) *) 'a lot of records' is not defined here ;)
Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-03 12:44 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-03 12:53 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-03 18:10 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-03 18:31 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-04 13:50 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-04 15:13 +0200
Re: sql order but move some rows bottom anver <NOSPAMM@NO.SPAMMS> - 2013-08-04 16:42 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-04 16:56 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-04 19:36 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-04 19:52 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-05 14:50 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-04 17:49 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-04 19:37 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-04 19:53 +0200
Re: sql order but move some rows bottom Luuk <luuk@invalid.lan> - 2013-08-04 20:20 +0200
Re: sql order but move some rows bottom nawfer <novalidsforspam@alt.al> - 2013-08-05 14:57 +0200
csiph-web