• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Why does XenForo use a seperate query to retrieve sticky threads?

#1
Hi Guys,

While I'm working on my mod I came acros the way stickies are handled and I was wondering why XenForo performs a seperate query to retrieve the stickies from the database.

In my mod which list downloads I also build a sticky function but I just sort the query results by attachment.sticky DESC, $secundaryOrder

I'm thinking this is due to 2 queries to the database are faster than sorting 1 but I'm not sure..

Regards,
Danny
 

cedivad

Active member
#2
You answered yourself ;)
Think at what appens when the sticky thread is older than 30 topics and you have limit 20 in the first query ;)