* Search and Replace version 3.3 strange result

For users to report plugin bugs and request plugin enhancements; and for authors to test new/new versions of plugins, and to discuss plugin development (in the Programming Technicalities sub-forum). If you want advice on choosing or using a plugin, please ask in General Usage or an appropriate sub-forum.
Post Reply
User avatar
johnhanson
Diamond
Posts: 67
Joined: 27 Nov 2002 16:50
Family Historian: V7
Contact:

Search and Replace version 3.3 strange result

Post by johnhanson »

I moved some addresses into the first part of the place field using the place/address plugin which of course leaves spurious codes - well documented and even has a suggestion for removing them using the Search/Replace plugin

I have tried that and even though the result says that it has done it when I run the "work with places" again it is still there - what amm I doing wrong? I notice that the Search/Replace has a close on the bottom and notice that having run the script to remove things

This is the result of the search/replace
Result of search/replace
Result of search/replace
Seaarch-Replace.jpg (184.5 KiB) Viewed 2173 times
This is the screen showinig what I ran
Sp-Script.jpg
Sp-Script.jpg (124.48 KiB) Viewed 2173 times
Having run it again the screen does not re-appear after it finishes so I can't close the plugin and wonder if that is the issue.

I have checked all open screens to make sure that it isn't lurking behind somewhere
John Hanson FSG
Researcher, the Halsted Trust
User avatar
tatewise
Megastar
Posts: 28413
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Search and Replace version 3.3 strange result

Post by tatewise »

Sorry John, I have to admit to being mystified. I've run the same scenario and it works as expected.

What is most odd is your screenshot of the Result Set on completion of the 'Search and Replace' plugin.
The Old Value and New Value columns are correct but the Record Name column shows the old value, not the new value.
I can only get that if I use Edit > Undo Plugin Updates.

Also, can you explain why the 'Search and Replace' plugin still seems to be 'Running' in that screenshot?
The Result Set cannot be produced until it has stopped running and automatically closes.

You say: Having run it again the screen does not re-appear after it finishes so I can't close the plugin.
Which screen does not re-appear?
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
User avatar
tatewise
Megastar
Posts: 28413
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Search and Replace version 3.3 strange result

Post by tatewise »

I have performed some more test runs and found one occurrence where despite what the Result Set says, the prefix has not been removed from one Place Record.
Let me investigate why.
Trying to repeat the symptoms is proving more difficult than expected, as sometimes it does and sometimes it does not.

I think I have a possible explanation.
For all those Places that should be , , X, Y, Z but retain their prefix, was there already a Place named , , X, Y, Z such that after removing the prefix two Place records would have the same name?
That would inhibit removal of the prefix.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
User avatar
johnhanson
Diamond
Posts: 67
Joined: 27 Nov 2002 16:50
Family Historian: V7
Contact:

Re: Search and Replace version 3.3 strange result

Post by johnhanson »

Mike
Happy to let you have a copy of the gedcom if it will help
Regards
John
ps Sorry been out with family all day
John Hanson FSG
Researcher, the Halsted Trust
User avatar
tatewise
Megastar
Posts: 28413
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Search and Replace version 3.3 strange result

Post by tatewise »

Don't worry I've been out with friends all afternoon.
I don't need the GEDCOM but a view of some Place records shown in the Records Window on the Paces tab will help.
Are there entries for , , , London, England or , , Bexley, Kent, England or any others shown under New Value?
i.e. They conflict with that New Value after the Old Value has its prefix removed.

So before running Search and Replace there are entries for:
, , , London, England
{JP0}, , , London, England
, , Bexley, Kent, England
{PX0}, , Bexley, Kent, England

Then when {JP0} and {PX0} are removed there would be pairs of Place records with the same name.
That is not allowed, so FH reverses the change and puts the prefix back.

That is something that the Search and Replace plugin could potentially detect and warn against.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
User avatar
johnhanson
Diamond
Posts: 67
Joined: 27 Nov 2002 16:50
Family Historian: V7
Contact:

Re: Search and Replace version 3.3 strange result

Post by johnhanson »

OK Mike
I will have a tidy up and then try again
Does make sense

Thanks again

Regards
John
John Hanson FSG
Researcher, the Halsted Trust
User avatar
johnhanson
Diamond
Posts: 67
Joined: 27 Nov 2002 16:50
Family Historian: V7
Contact:

Re: Search and Replace version 3.3 strange result

Post by johnhanson »

Having had a good look at the offending entries it would appear that they all had a "use count" of zero and the vast majority had other entries

So I took the plunge and deleted all the place with a 0 use count - happy bunny now

Thanks Mike and next time I'll do some house keeping inbetween rather than try and do things one after the other

Might work some times but not always

Regards
John
John Hanson FSG
Researcher, the Halsted Trust
User avatar
tatewise
Megastar
Posts: 28413
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Search and Replace version 3.3 strange result

Post by tatewise »

Thank you for the feedback John.
Yes, after using the Rearrange Place and Address Parts plugin there usually needs to be a tidy-up of Place records.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry
Post Reply