Gossamer Forum
Home : Products : Gossamer Links : Discussions :

How to fix a corrupted category tree table

Quote Reply
How to fix a corrupted category tree table
Just spent 2 long days work on filling out content and now I have hit a database corruption problem, in all my experience using links this is a new one on me and I really hope someone can suggest a fix, I dont really want to start again if I can help it.

Heress the error for rebuilding the category tree :

Adding Category tree...

A fatal error has occured:
No parent category found for Business/Transportation and Logistics/Freight Forwarding! Your Category table is corrupted

I tried the SQL REPAIR TABLE command but no effect.

Previously the error was on another category, I tried searching out that one and deleting but then it just moven on to another error shown here.

Any suggestions please?
Quote Reply
Re: [roman365] How to fix a corrupted category tree table In reply to
Mmm, how were you adding the data?

Its not that simple to fix that error.


Quote:
No parent category found for Business/Transportation and Logistics/Freight Forwarding! Your Category table is corrupted

That basically means that it can't find "Business/Transportation and Logistics" (i.e the parent category)

This either means its been deleted - or you've renamed it, and for some reason the sub-categories were not updated properly.

I can try doing some debugging for youy if you want, but I'd have to charge (as its got potential to takes ages to find the issue)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] How to fix a corrupted category tree table In reply to
Thanks for responding.

I was using the dmoz script you wrote, we were talking by email a couple of days ago ;)

Ive been keeping an eye for a newer rdf release but its still sitting at sept 11.

I have a horrible suspicion its down to the dreadfully bad rdf content file as you discovered. I'm certainly sure its not your dmoz script, it has always performed well for me in the past.

I managed a dmoz run for most of the content and then more targeted runs for small pieces here and there and also did couple of small spider runs for a few links here and there.

During those processes I was moving the occasional driectory here and there.

Unfortunately I cant say for sure which of the last few operations it occured on.

If I have to start again then thats ok I suppose, at least it was only a couple of days effort, I was just hoping there might be a potential remedy operation possible. At this early stage its not really ecenomical to pay for a fix, however if it was a mature and valuable site I would have no problem comissioning your services.

Last edited by:

roman365: Sep 17, 2009, 12:57 AM
Quote Reply
Re: [roman365] How to fix a corrupted category tree table In reply to
Hi,

Ah ok - I think its probably down to where you were moving the categories around. I'm guessing you were doing it via "Browse" ? I've had issues with that before - where it doesn't seem to update fully when moving categories around. I tend to do mass-moves via SQL queries, which leaves less chance of a mess up =)

What I'd suggest, is re-doing the imports - and then let me know what you wanna move from where (I need the "father" category ID of the one you wanna remove, and the Full_Name - and then I should be able to give you some commands to run, which will move them around without damaging the category structure

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] How to fix a corrupted category tree table In reply to
Yep, via browse.

Although I've never previously encountered the issue as you describe it makes sense.

What I'm doing is basically grabbing one of the regional categories and using a specific country as the rootlevels and using the rest in a sublevel for "other" countries related to the region, then updating all the symbolically linked cats and any that fall outside of the region category I'm subsequently fetching the real cats and moving into the same location as the original symbolic categories so thereby mimicing the dmoz structure of the country category. From there I'll then develop it further in a more unique style so as not to get penalised for being another dmoz clone SEO wise.

The list could get very long obviously for fetching the content of the symbolic categories and moving them into the directory structure locations, probably best I just have a go myself, basically restart and do more regular backups :)

The move commands would be very handy if you want to share thanks.
Quote Reply
Re: [roman365] How to fix a corrupted category tree table In reply to
Hi,

Ok =)

Here is an example. Lets say you have a category:

Regional/UK/England (ID 1234)

...and you wanna move that to

UK/England

What you would do, is run these commands:
Code:
UPDATE glinks_Category SET Full_Name = REPLACE(Full_Name,"Regional/UK/England","UK/England") WHERE ID = 1234 OR FatherID = 1234;

Untested, but should work ok for ya :)

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] How to fix a corrupted category tree table In reply to
Ok, thanks very much Andy. I'll give it a try.

Now all I need to do is get restarted, wondering how long the content rdf gets updated at dmoz. Trying to decide to wait and see if next one isnt so broken before carrying on, have a number of pulls to do fo different ideas.
Quote Reply
Re: [roman365] How to fix a corrupted category tree table In reply to
Hi,

Afraid I'm not sure how often the RDF file gets updated - maybe once a week, or maybe even once a month :(

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] How to fix a corrupted category tree table In reply to
Yeah, Ive heard it can vary a lot between those timescales.
Quote Reply
Re: [Andy] How to fix a corrupted category tree table In reply to
Andy's guess is right..

http://www.dmoz.org/help/getdata.html

Q: How often is the RDF data updated?
A: We begin the process of creating a new RDF every Monday. This process currently completes by Friday morning.

Vishal
-------------------------------------------------------
Quote Reply
Re: [SWDevil.Com] How to fix a corrupted category tree table In reply to
Well thats the updated rdf out a week later so you guys are right enough, it does seem weekly right now.

Current one fetched and processing, hopefully its not badly messed up like the previous one.