YEAH !
Solved.
To come back to the beginning, if someone is looking for Avpicfacexmptagger software, I have put it in my iptc-softwares page :
http://orchisere.pagesperso-orange.fr/logiciels/html/IPTClogiciel.htm#apfxtdirect link :
http://orchisere.pagesperso-orange.fr/ztele/avpicfacexmptagger_1.7.zipThis software does the job, even if faces are in different groups (family, friends, celebrities ...) but doesn't write root hierarchical keyword alone (the reason why I'm using ExifTool)
I followed Stargeek's advice.
I would instead suggestion combining the commands that add metadata, then running a second command to remove duplicate Keywords and HierarchicalSubject. Something like this:
exiftool -config picasa_faces.config -if "$PicasaRegionNames" -api "Filter=s/^/Family|/" "-xmp-lr:hierarchicalsubject+<PicasaRegionNames"
For this first step, I added # in expression -if "$PicasaRegionNames#" I dont know if it's necessary, but I got best results in some other tests.
Then I moved -iptc:keywords+<PicasaRegionNames# and -xmp-lr:hierarchicalsubject+=family" to an -@argfile
Result, my first shortcut (named Full Keywords) contains :
exiftool -config C:\Tool\conf\picasa_faces.config -if "$PicasaRegionNames#" -@ "C:\Tool\conf\args.txt" -api "Filter=s/^/Family|/" "-xmp-lr:hierarchicalsubject+<PicasaRegionNames" Where C:\Tool\conf\args.txt file contains :
-xmp-dc:subject+<PicasaRegionNames#
-iptc:keywords+<PicasaRegionNames#
-xmp-dc:subject+=family
-iptc:keywords+=family
-xmp-lr:hierarchicalsubject+=family
-k
(I could not use neither "-api" for hierarchicalsubject nor "-if PicasaRegionNames" inside the args file, results were different for some photos)
Second step, remove duplicates, as suggested by StarGeek.
exiftool -sep "##" "-xmp-lr:hierarchicalsubject<${xmp-lr:hierarchicalsubject;NoDups}" "-iptc:keywords<${iptc:keywords;NoDups}" "-xmp-dc:subject<${xmp:subject;NoDups}"The advantage of this second step is to eliminate any duplicates in all keywords and photos, even if Picasa Faces has not been used.
One day, I'll add -r to these shortcuts ... :scared:
Many thanks for this help, I understood a lot of new methods, that I'll have to explain in my own ExifTool page