* Move data between fields

Questions regarding use of any Version of Family Historian. Please ensure you have set your Version of Family Historian in your Profile. If your question fits in one of these subject-specific sub-forums, please ask it there.
Post Reply
User avatar
Xaav
Newbie
Posts: 3
Joined: 11 Apr 2023 09:45
Family Historian: V7
Location: Belgium

Move data between fields

Post by Xaav » 11 Apr 2023 11:09

Good morning,

I'm brand new FH7 user testing for 8 days.
I've been on TMG since 2008 and currently on version 9.05.
I made an import in FH7 and it went very well.
FH7 seems very close to TMG and would be a very good replacement.

I still have a question:
For an attribute type Tag, the imported data is placed in the {note} field. Is it possible to move them to the {value} field of this same tag?
This concerns more than 5400 records, so it is not possible to do it manually.
Being a very new user, I do not yet know the most advanced possibilities of the software.

Sorry for mistakes or inaccuracies, I speak French and I used Google Translate.

Thank you, Xaav

User avatar
tatewise
Megastar
Posts: 27074
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Move data between fields

Post by tatewise » 11 Apr 2023 12:32

Welcome to the FHUG Xaav.

The problem you describe often happens when importing to FH.
FH makes a strong distinction between Events (such as Birth, Marriage, Census & Death) and Attributes (such as Occupation, Education, Religion & Physical Description).

Events cannot have a {value} whereas Attributes can have a {value}.

Exactly what Tags/Facts are you talking about?
If they are Events then the {note} cannot be moved to the {value} field.
It is possible with a plugin to change custom Events into custom Attributes.
However, standard Events should not be changed.

So we need more details about the Tags/Facts before we can suggest a solution.
You can provide screenshots of the Facts that might be useful.
See FHUG Knowledge Base > Forum Usage Tips under Attachments and Taking Screenshots.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
Xaav
Newbie
Posts: 3
Joined: 11 Apr 2023 09:45
Family Historian: V7
Location: Belgium

Re: Move data between fields

Post by Xaav » 11 Apr 2023 13:26

Thank you for this quick response.
The Ref-Chrono tag was imported from TMG as "Event - TMG Import (project).
Using the "Change any fact Tag v3.8" plugin, it was transformed into "Attribute - Tmg Import"
ref-chrono2.JPG
ref-chrono2.JPG (52.55 KiB) Viewed 566 times
Now I would like to push the data from the {note} field to the {value} field
ref-chrono 1.JPG
ref-chrono 1.JPG (29.53 KiB) Viewed 566 times
i hope this helps

User avatar
tatewise
Megastar
Posts: 27074
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Move data between fields

Post by tatewise » 11 Apr 2023 14:17

I am impressed that you already found the Change Any Fact Tag plugin.

Presumably, you found the advice in the FHUG Knowledge Base for Importing to Family Historian under the Import from The Master Genealogist (TMG) section.
You may also find the topics in Importing useful, especially Handling Uncategorised Data Fields.

I have several custom plugins for moving data fields so I quickly adapted one for this case.

The attached Move Chosen Fact Note to Value plugin Version 0.1 Date 11 Apr 2023 should work for you.
Run it and at the initial prompt enter your Attribute Name: REF - CHRONO and click OK.
If there are any problems then let me know.
Attachments
Move Chosen Fact Note to Value.fh_lua
Version 0.1 Date 11 Apr 2023
(2.81 KiB) Downloaded 24 times
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
Xaav
Newbie
Posts: 3
Joined: 11 Apr 2023 09:45
Family Historian: V7
Location: Belgium

Re: Move data between fields

Post by Xaav » 11 Apr 2023 14:46

Fantastic, that's exactly it!
ref-chrono3.JPG
ref-chrono3.JPG (32.51 KiB) Viewed 547 times
5455 changes made !
A big thanks
:D :D :D

User avatar
ACGenea
Silver
Posts: 8
Joined: 12 Apr 2023 14:59
Family Historian: V7
Location: Groningen, Netherlands
Contact:

Re: Move data between fields

Post by ACGenea » 12 Apr 2023 15:33

Hello,
I am new to FH as well and I've been using Legacy until now. But now I'll be using FH instead. Lots of great features!

Opening my Legacy file goes very well in FH, but I've come across a small problem. I think a small adaption of the plugin 'Move chosen fact-note to value' might be able to solve my problem.

Let me explain:
All occupations have been stored in the occupation-note instead of the occupation-field. Some occupation-notes are real notes, but most of them are one word - which should be the value of the occupation. I have already manually edited a lot of records, but it takes a lot of time.
For example in my database of over 8100 individuals there are over 400 with the value 'landbouwer' (farmer) in occupation-note and no value in 'occupation'.
occupation.jpg
occupation.jpg (16.78 KiB) Viewed 478 times
Is it possible to edit the plugin 'Move chosen fact-note to value' so that it selects occupation-facts of which the value in occupation-note is just one word (so regular notes are not moved) and the value in occupation is empty. And then move the one-word-occupation-note to the occupation field?

Or maybe to select all occupation-facts with a certain occupation (for example 'landbouwer') in occupation-note, and an empty occupation-field, and move the chosen occupation to the occupation-field (and remove it from the occupation-note).

I know I still have to manually edit a lot of records, but most of it could be done with the adapted plugin.

I hope this makes sense. And I hope it's okay that I replied to this thread instead of starting a new thread.

I really like FH and hope in the future I will be able to write my own plugins and queries, it just takes some time to get to know FH well and learn it.

Arjanne
(ACGenea)

User avatar
tatewise
Megastar
Posts: 27074
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Move data between fields

Post by tatewise » 12 Apr 2023 19:13

Hi Arjanne. Welcome to the FHUG.

Try the attached Move Chosen Fact Note Word to Value plugin Version 0.1 Date 12 Apr 2023.

It should work for your Occupation case of moving a single word Note to an empty value.
It will work similarly for other Attribute facts.

After running the plugin, if anything looks wrong use Edit > Undo Plugin Updates before closing FH to undo the plugin changes.

Alternatively, you can revert to one of the FH Snapshots taken each day.
Attachments
Move Chosen Fact Note Word to Value.fh_lua
Version 0.1 Date 12 Apr 2023
(2.94 KiB) Downloaded 25 times
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

User avatar
ACGenea
Silver
Posts: 8
Joined: 12 Apr 2023 14:59
Family Historian: V7
Location: Groningen, Netherlands
Contact:

Re: Move data between fields

Post by ACGenea » 13 Apr 2023 14:20

Hello Mike,
Thank you so much! It works really well and has saved me lots of time!
Thanks!

User avatar
tatewise
Megastar
Posts: 27074
Joined: 25 May 2010 11:00
Family Historian: V7
Location: Torbay, Devon, UK
Contact:

Re: Move data between fields

Post by tatewise » 13 Apr 2023 14:46

I'm glad that worked the way you wanted.
Take a look at the plugin script and use it as the basis for learning how to write similar plugins to move field data.
There is also lots of advice in the FHUG Knowledge Base on Plugins.

For Queries see An Overview of Queries.
Mike Tate ~ researching the Tate and Scott family history ~ tatewise ancestry

Post Reply