-filename<$DateTimeOriginal rename problem

Started by OOmatrixOO, July 18, 2017, 03:14:54 PM

Previous topic - Next topic

OOmatrixOO

Hello.
I use this to rename my photos. And it work.
exiftool -o "Bearbeitet/" -fileOrder DateTimeOriginal "-filename=#%%1.3C.%%le" "-filename<$DateTimeOriginal %%1.3C.%%le" -d %%Y-%%m-%%d -ext jpg

But if i set a underscore after $DateTimeOriginal, it doesnt work anymore.
exiftool -o "Bearbeitet/" -fileOrder DateTimeOriginal "-filename=#%%1.3C.%%le" "-filename<$DateTimeOriginal_%%1.3C.%%le" -d %%Y-%%m-%%d -ext jpg

What can I do to make this work?

Thanks.

StarGeek

Because you're adding characters directly onto the end of the tag name, the tag names needs to be separated from the rest of the command.  You can use brace { } characters to do this (see the docs under the -p option).  So try this as your command:

exiftool -o "Bearbeitet/" -fileOrder DateTimeOriginal "-filename=#%%1.3C.%%le" "-filename<${DateTimeOriginal}_%%1.3C.%%le" -d %%Y-%%m-%%d -ext jpg
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype