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

Quick way to find alt-links?

Quote Reply
Quick way to find alt-links?
Hi, I am having sorting problems and have narrowed it to my alt-links. Is there a quick way (perhaps with an SQL query) to find my alt-links so I can move them into one category only?

Thanks...

Quote Reply
Re: Quick way to find alt-links? In reply to
The alternate list is stored in the table : CategoryAlternates

Moving all the alternate links to one category doesn't make much sense, since the reason for alternate categories was to put them into relevant areas.

It makes much more sense just to delete all your alt-links, and you can do that by:

DELETE * FROM CategoryAlternates

(I think).

Deleting an alt-link just removes the CategoryID:LinkID relationship from the CategoryAlternates table. Rebuild, and they'll be gone.


http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/

Quote Reply
Re: Quick way to find alt-links? In reply to
Thanks for the reply PugDog...

I entered this command in the TABLE MAINTENANCE>LINKS>SQL MONITOR and received the following output:

Query Error: parse error near '* FROM CategoryAlternates' at line 1

Any idea what went wrong?

Also, just to confirm, this won't delete the links from the database, correct, it will just delete any alternate categories that have been assigned to them?

Thanks again!


Quote Reply
Re: Quick way to find alt-links? In reply to
Ooops.. yes.. the '*' was not necessary.

Sorry about the late reply, but I'm just being able to connect back to the board. Looks like the problems are fixed (at least for now).

Just DELETE FROM CategoryAlternates

You can add a "WHERE" clause, but you don't want one in this case, since you just want to delete all the links.

It won't touch anything in the rest of the links tables, just the "alt-links".'

It won't touch the CategoryRelations, since that is in another table as well.

All it will do is get rid of links in categories that are _NOT_ specified in the actual Links record (the primary category).


http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/