Gossamer Forum
Home : Products : Gossamer Links : Discussions :

when to rebuild or reindex

(Page 2 of 2)
> >
Quote Reply
Re: [afinlr] when to rebuild or reindex In reply to
Thanks Laura,

I knew I had it wrong. I think that this can be an extremely useful tool for many directories, I know it is for mine.

Quote:
This all came about while I was testing on real people, one of the people tapped in hairdresser essex and it said no result but there are results and so my questions went from there. I wouldn't have stopped to try that side of things so in some ways I'm glad I did.

It's interesting that when you spend a lot of time working on your own Links SQL site, you can sometimes not realize how actual users respond to your site. Things that you think would be obvious sometimes just aren't. Also, you can miss some things like this example, that you might not notice on your own. I think KevM was very smart to do this kind of testing.

--FrankM
Quote Reply
Re: [afinlr] when to rebuild or reindex In reply to
Thought I'd better add a (hopefully) error free version of the file in case anyone else wants to use it.

I've changed it slightly so that it only updates Links where the new field is empty - so that you can run it again and it will just update the links which have been added since the last time you ran it. Alternatively, you could of course just run it once and then add the keywords to your new records as you add them.
Quote Reply
Re: [FrankM] when to rebuild or reindex In reply to
Totally agree - it's amazing the strange places that people get stuck when you look over their shoulder! I definitely don't do enough of this on my site but it is extremely important. Especially when it's so easy for people to leave your site and use a different one if it doesn't behave as expected.
Quote Reply
Re: [afinlr] when to rebuild or reindex In reply to
Hi,
Maybe I got something wrong when I read the message. I ended up with a headache+migraine that knocked me out for about 6 hours. Worst one I've had in a long, long time.

But, the concept here is still a "quick fix" vs the more useful/elegant/proper/? solution.

If a link/node/leaf, in this case a Link record, needs some sort of other data to qualify it, eg: Location, color, size, manufacturer, etc it should be included as a field in the Link record. If there is a business classification system, then the category of the business should also be included, such as the category in a yellow pages. Don't rely on the category hierarchy -- a convenience thing -- to determine the characteristics of the node data.

Part of data normalization is recoverability, data integrity, etc. which is why no database is ever perfectly normalized, but usuallybrought to a 3rd normal (more or less) level.

In the case of this link, a category/categorization field eg "Hairdresser" should be included in the link. Also the location of the link. City, State, Zip, or whatever unique localization information would give the user the data/information they need.

In the case of the link being orphaned from the category hierarchy, there is enough information to know that this link is a business class "Hairdresser" and in the region/location of "city, state, zip".

That link could be "automatically" recategorized, even if the actual category layout changed.

On top of that, in a search, the node/leaf contains enough information to uniquely identify it, as well as categorize it for the users search.

Links SQl got rid of the concept of primary categories, and even category ownership of a link to allow related, multiple and other category features. While in general,that is a good thing, sometimes building in some of the data contained in a "primary category" system is also a good thing -- especially for a true directory were there are several attributes of the link that are important -- eg type of business & location in this case.

So, the true solution here, as evidenced by the last few messages even, is a change to the Links table to reflect the data people are trying to use, rather than relying on keywords being present in the title, description or even category placement of the link.

Adding in a "Category" and "Location" or "City" field (depending on the scope of the directory) would solve the problem better. In that case, someone could do a search on "Essex" to find any businesses that were in any category and perhaps be surprised at what they found (ie: a bead shop popping up out of the list <G>) The link could be classified under "Hairdressers", "Personal Grooming", "Beauty & health", "Spas" or "Essex" and still be found on a search or perusal of the category system (if the link.html showed that data).

So, the fix is to change the link record, and the type of data collected and associated with the link.

A quick fix, as outlined here, is to give a potential keyword assist.

But, as the directory grows and changes, the long-term fix is a better solution, and can be started now, and worked backwards as links are updated, but going forward, new links will have the proper classification (search) data associated with them.

Not trying to be a pain, really. While andy is running around having fun with coding, I've been stuck with a few situations of redesiging somewhat complex databases. It's like those logic problems where you get a story and a bunch of clues like who is sleeping with whom, and what color car they drive, and you need to figure out if they smoke or like roast beef sandwiches :)


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Quote Reply
Re: [afinlr] when to rebuild or reindex In reply to
Hi,

Thanks to everyone for their help and assistance. I am going to run the new cgi in a minute.

I have actually already set up town field so future wise this is already structured correctly and in place but part of the issue was that I had also given myself a bit of a leg up by using a DMOZ dump and I needed to compensate for the way that data was handled.

Anyway thanks again and happy easter

Kevin

Cheers
KevM
Quote Reply
Re: [KevM] when to rebuild or reindex In reply to
Hi,

this really hasn't worked out as i hoped, one way or the other i had to do a reindex and it then a build changed went on to rebuild everything. What has happened now is that all my category names have been changed to 'Internet' bar a couple. I have no categories of any meaning.

I have got no idea what is happening but I have got some backups, just not sure if I have the right ones. The problem is I can't get this cgi program out of the system so everytime I rebuild changed it overwrites again.

It is my own fault and I shouldn't have run it but could someone tell me what I need to restore from my backup to get this in place again as it was yesterday at 3.00pm and how can I undo what the cgi program has done to whatever it has changed, it turned out to have a few errors in it on the first version that i ran.

I've got myself in way over my head with this.

Many thanks,

Kevin

Cheers
KevM
Quote Reply
Re: [KevM] when to rebuild or reindex In reply to
Hopefully I'm sorting Kev's problem out now. This was unfortunately due to the error in the original script combined with Kev's choice of name for the new field very unfortunately matching the name of a field in the Category table.

I'd be grateful if a moderator could delete the attachment at the beginning of this thread just in case anyone else uses it.

Thanks,
Laura.
The UK High Street
Quote Reply
Re: [afinlr] when to rebuild or reindex In reply to
SmileHi,

just wanted to say that my links sql is fully ok now thanks to the efforts of afinlr and the mod, now it is installed correctly, is absolutely spot on and works flawlessly, I can now find hairdressers in essex that have been imported from my DMOZ dump and doesn't return 'no matches' as it did before.

I think it was just down to bad luck that I named my new field Names because this mod actually works very well so, for anyone else reading this thread who wants to make use of this excellent little script, use something for FILENAME that has no relation to any fields you already have. Might sound obvious now but I didn't realise just how much impact it would have.

Thanks especially again to afinlr (Laura) for all your help,

Happy Easter!

Cheers
KevM
> >