Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Sort problems

Quote Reply
Sort problems
I'm having a problem with sorting links in Links SQL. No matter what I do, greatest # of hits ends up at the bottom, rather than the top.
Alex doesn't seem to be helping, any suggestions?
Quote Reply
Re: Sort problems In reply to
What are you trying?

You should be able to set the sort paramters to "Hits DESC" to get them to sort highest hits first.

If you have a lot of alt-links this may not work well, see the other threads on the search bugs/problems.


------------------
POSTCARDS.COM -- Everything Postcards on the Internet www.postcards.com
LinkSQL FAQ: www.postcards.com/FAQ/LinkSQL/








Quote Reply
Re: Sort problems In reply to
I've set Links.pm as:
$LINKS{build_sort_order_category} = "Hits,isPopular,Title";

More hits moves it to the bottom, popular didn't work, it ended at bottom, Title is alphabetical

------------------
www.serveyou.com
Quote Reply
Re: Sort problems In reply to
Look at what I wrote above.

The program is doing what you asked it to. It's sorting Hits in ASCending order. You want it to sort in DESCending order.
Quote Reply
Re: Sort problems In reply to
Thank you VERY much. It worked. I've been trying to get Alex to help with this for the last couple of weeks.
Is there also a way to get the listings from alternate categories with high hits to show up high on the list?
My preferred sort order would be:
# of hits (main category) (3000+)
# of hits (Alt category) (3000+)
We set all paid listings at 3000+ hits, free listings at 0
Again, thanks. Beer's on me if you ever come to Socal

------------------
www.serveyou.com
Quote Reply
Re: Sort problems In reply to
Right now, no. The problem is how the hash of Links and alt-Links are merged together.

If the fix is not availabe in the next Links release, I'll make a hack available that will re-sort the merged links, but it certainly is not a performance hack, and it might not work really well on large sites due to the overhead.