ExifTool Forum

ExifTool => Newbies => Topic started by: frank_rap on April 30, 2018, 07:59:15 AM

Title: add xmp keywords to all raw files via csv
Post by: frank_rap on April 30, 2018, 07:59:15 AM
Hey Guys

Struggling to get this working.

I want to add a keyword to all the raw files in a subfolder from csv file.

folder structure looks like

the.csv
subfolder01
    subfile01.cr2
    subfile02.cr2
    subfile03.cr2
    subfile04.cr2
subfolder02
    subfile05.cr2
    subfile06.cr2
    subfile07.cr2
    subfile08.cr2

csv file looks like

SourceFile,iptc:keywords
subfolder01/*.CR2,Test
subfolder02/*.CR2,Test2


Have tried exiftool -csv=test.csv ./*/*.CR2 -v2

but get error
No SourceFile './subfolder02/_71A9912.CR2' in imported CSV database

Thanks is advance

Title: Re: add xmp keywords to all raw files via csv
Post by: Phil Harvey on April 30, 2018, 10:51:37 AM
Wildcards are not allowed in the SourceFile column, with the exception that "*" may be used to represent any file (in any directory).

I suggest using some method other than CSV.  It would work if you could use the CSV file to generate a set of commands like this:

exiftool -iptc:keywords="Test" -ext cr2 subfolder01
exiftool -iptc:keywords="Test2" -ext cr2 subfolder02


- Phil