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

Duplicate Category Paths!

Quote Reply
Duplicate Category Paths!
Hi,

I found several duplicates in my category table (my own fault for adding them) and wondered if this is unique to my installation, an unreported bug within LSQL, or not really a problem at all?

I say bug, because I assumed that category path would have to be unique otherwise there is a potential for the build process to select from any number of category ID's where duplicate path-names exist, and as such a potential for links to be assigned to a variety of category ID's for the same path-name.

It may, however, not be a problem if the links are grouped by the category 'name' (path) rather than the ID during the build process.

Can anyone enlightenment me? Am I just confused? Have I OD'd on Links? <hehehe>!

All the best
Shaun

Quote Reply
Re: Duplicate Category Paths! In reply to
I think Alex answered this in another thread.

If you find duplicates, the best thing to do is to issue an SQL command to

UPDATE Links SET CategoryID = "good category number" where CategoryID = "bad category number"

Then delete the "bad category"

Alternatively, you could "risk" letting Links do this for you, by deleting the "bad category" then using the find bad links and "moving" them to the "good category number"



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

Quote Reply
Re: Duplicate Category Paths! In reply to
Hi Pugdog,

Actually I do it by downloading a copy of my 'category' table from my server into MS Access and do a query to find duplicate categories in the 'Name' (path) field. Where I find dupes I go on-line and use the admin panel to remove the duplicates that have 0 (zero) links in them.

I know how I've got duplicates in the first place, its because I've been importing them and adding them manually and obviously managed to do some of them twice. I mentioned it because I would have thought that having two identical category 'paths' and therefore two ID's would not be desirable, and wanted to make other LSQL users aware of the potential for dupes :)

Is there a way I can set the category 'Name' field to be unique either within the table or Links?

All the best
Shaun

Quote Reply
Re: Duplicate Category Paths! In reply to
Just set the "unique" field to on using MySQLMan or an SQL query for the Category.Name field.

I can't, off the top of my head, see where in the normal course of things that would cause a problem.

Do that, then try to do an addition via the Links Admin and see if you get a program crash, or an error "Duplicate Name not allowed" or something like that.



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

Quote Reply
Re: Duplicate Category Paths! In reply to
Thanks Pugdog Smile

All the best
Shaun