next/previous entry linking
Posted: 09 July 2008 11:21 AM   [ Ignore ]  
Grad Student
Rank
Total Posts:  45
Joined  12-10-2003

EE version 1.6.4 build 20080626

After upgrading from 1.5.2 to 1.6.4 I found that the next/previous links didn’t work properly.

In my case the posts were created in random order then the entry date was changed to put them in the right order.

Example: for entry id 64 the following query will look for next entry.

SELECT t.entry_id, t.title, t.url_title
FROM
(exp_weblog_titles AS t)
LEFT JOIN exp_weblogs AS w ON w.weblog_id = t.weblog_id
WHERE t
.entry_id != 64 AND t.entry_date < 1215636832 AND t.entry_date >=1168633682
AND t.entry_id > 64 AND (t.expiration_date = 0 OR t.expiration_date > 1215636832)
AND
w.is_user_blog = 'n' AND w.site_id IN ('1') AND w.blog_name = 'plains' AND t.status != 'closed' AND t.status = 'open'
ORDER BY t.entry_date ASC, t.entry_id ASC LIMIT 1

One condition is entry_id > 64. In my case the next entry is 63 because they were initially entered in random order so the query will not return the expected result.

Is this the intended behavior or is a bug?

Thanks,
Gabriela

Profile
 
 
Posted: 09 July 2008 11:28 AM   [ Ignore ]   [ # 1 ]  
Administrator
Avatar
RankRankRankRankRankRankRank
Total Posts:  15831
Joined  06-03-2002

Hi Gabriela, the fix was intentional (for this reported bug), this side effect was not.  We’re working on a more appropriate fix for the next build.  Thanks for reporting!

 Signature 
Profile
MSG
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 64937 Total Logged-in Users: 61
Total Topics: 81905 Total Anonymous Users: 30
Total Replies: 440292 Total Guests: 310
Total Posts: 522197    
Members ( View Memberlist )