Gossamer Forum
Home : Products : Gossamer Links : Discussions :

multi add to additional categories

Quote Reply
multi add to additional categories
I am doing fresh imports links from text delimited files. Because these do not have an ID issued by GLinks, I can only allocate one category. (GLinks thinks multiple copies of same link with different category IDs are individual links)

I now want to place some of these links in additional categories. There are approx 500 links in each import file. Is there an easy command to use to do this through SQL Monitor? Something like:

UPDATE prefix_CatLinks ADD CategoryID = 'n' WHERE Type LIKE 'XX'

and also have the LinksID copied from the record where Type LIKE 'XX' was found.

Thanks in advance

Quote Reply
Re: [Alba] multi add to additional categories In reply to
There's no "easy" way.

You actually have to insert/create a record in the CatLinks table. It's a much more complicated SQL statement.

I had some code awhile back that let me do something like that, but you had to give it the ID's of the links. It worked for me, because all the links I was inserting were consecutive ID's.

If you are going to be doing this a lot, writing a short perl script might not be a bad idea.

You could give it the starting ID to check, then insert new records based on the Type.


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Quote Reply
Re: [pugdog] multi add to additional categories In reply to
Thanks,

This should only need to be done once (unless I get other datafeeds in the future that need the same).

I'll take another look and see what is possible.