MantisBT - Piwigo
View Issue Details
0002540Piwigoconfigurationpublic2011.12.21 14:252012.02.10 14:45
plg 
mistic100 
normalmajoralways
closedfixed 
2.3.2 
2.3.32.3.3 
any
Apache 1.3.x
0002540: When default photos order is only by rank, failure outside albums
If your default photos order is only on the rank, then if you display some photos outside an album (on a tag, or on most_visited for instance), you get something like :

SELECT DISTINCT(id)
  FROM images
    INNER JOIN image_category AS ic ON id = ic.image_id
  WHERE image_id IN (1,2,3)
  ORDER BY
; in /.../include/dblayer/functions_mysql.inc.php on line 767

There is no ORDER BY.
No tags attached.
Issue History
2011.12.21 14:25plgNew Issue
2011.12.21 14:25plgStatusnew => assigned
2011.12.21 14:25plgAssigned To => mistic100
2011.12.21 14:25plgbrowser => any
2011.12.21 14:25plgWeb server => Apache 1.3.x
2012.01.08 18:39mistic100Note Added: 0005907
2012.01.10 20:53plgNote Added: 0005915
2012.01.10 21:50svnCheckin
2012.01.10 21:50svnNote Added: 0005916
2012.01.15 16:20mistic100Statusassigned => closed
2012.01.15 16:20mistic100Resolutionopen => fixed
2012.01.15 16:20mistic100Fixed in Version => 2.4.0beta2
2012.01.15 16:20mistic100Statusclosed => feedback
2012.01.15 16:20mistic100Resolutionfixed => reopened
2012.01.15 16:20mistic100Statusfeedback => closed
2012.01.15 16:20mistic100Resolutionreopened => fixed
2012.01.15 16:20mistic100Fixed in Version2.4.0beta2 => 2.3.3
2012.02.05 15:23plgNote Added: 0005989
2012.02.05 20:17mistic100Note Added: 0005990
2012.02.05 20:17mistic100Statusclosed => feedback
2012.02.05 20:17mistic100Resolutionfixed => reopened
2012.02.05 20:50plgNote Added: 0005991
2012.02.05 21:20mistic100Note Added: 0005992
2012.02.06 21:22svnCheckin
2012.02.06 21:22svnNote Added: 0005993
2012.02.10 14:45plgStatusfeedback => closed
2012.02.10 14:45plgResolutionreopened => fixed

Notes
(0005907)
mistic100   
2012.01.08 18:39   
what must be the order instead ?
ORDER BY date_available DESC, file ASC, id ASC
as for Piwigo default configuratio ?
(0005915)
plg   
2012.01.10 20:53   
I would just do a simpler "ORDER BY id ASC"
(0005916)
svn   
2012.01.10 21:50   
[Subversion] r12872 by mistic100 on trunk

-----[Subversion commit log]----------------------------------------------------
bug:2540 When default photos order is only by rank, failure outside albums
define a default order_by + some javascript for limit number of fields
(0005989)
plg   
2012.02.05 15:23   
If we have 2 criteria on Rank and no other, the bug still occurs.

For example : criterium1=Rank ascending, criterium2=Rank descending
(0005990)
mistic100   
2012.02.05 20:17   
can't we block all identical criterias ? that could prevent some misunderstanding
(0005991)
plg   
2012.02.05 20:50   
What is an "identical criteria"? are "rank asc" and "rank desc" identical?
(0005992)
mistic100   
2012.02.05 21:20   
yeah that's what I mean
(0005993)
svn   
2012.02.06 21:22   
[Subversion] r13037 by mistic100 on branch 2.3

-----[Subversion commit log]----------------------------------------------------
merge r12872 from trunk
bug:2540 When default photos order is only by rank, failure outside albums