Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

overwrite=true does not work for fieldtarget #535

Closed
moewew opened this issue Feb 13, 2017 · 3 comments
Closed

overwrite=true does not work for fieldtarget #535

moewew opened this issue Feb 13, 2017 · 3 comments
Assignees
Labels

Comments

@moewew
Copy link
Collaborator

moewew commented Feb 13, 2017

This came up in http://tex.stackexchange.com/q/353722/35864

It seems as though overwrite=true has no effect when used in a fieldsource/fieldtarget combination.

In the MWE below I would expect both notes to show 'foo', yet in worman the original value 'bar' is not overwritten.

\documentclass{article}
\usepackage{filecontents}
\usepackage[
  backend=biber,
  style=authoryear-comp,
]{biblatex}

\DeclareSourcemap{
  \maps[datatype=bibtex]{
    \map[overwrite=true]{
       \step[fieldsource=keywords, fieldtarget=note]
    }
  }
}

\begin{filecontents}{\jobname.bib}
@book{worman,
  author    = {Worman, Nancy},
  title     = {The Cast of Character},
  date      = 2002,
  keyword   = {foo},
  note      = {bar},
}
@book{wilde,
  author   = {Wilde, Oscar},
  title    = {The Importance of Being Earnest},
  year     = 1899,
  keywords = {foo},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}
\nocite{*}
\printbibliography
\end{document}
@moewew moewew changed the title overwrite=true does not work for fieldtraget overwrite=true does not work for fieldtarget Feb 13, 2017
plk added a commit to plk/biber that referenced this issue Feb 17, 2017
@plk plk self-assigned this Feb 17, 2017
@plk
Copy link
Owner

plk commented Feb 17, 2017

This was a bug, now fixed in 2.8 DEV version.

@moewew
Copy link
Collaborator Author

moewew commented Feb 18, 2017

Thank you for the swift reply. It works like a charm with the 2.8 DEV version from sourceforge.

@plk plk closed this as completed Apr 15, 2017
@moewew moewew added the bug label Jun 8, 2017
@plk
Copy link
Owner

plk commented Sep 29, 2017

Yes, you need the DEV 2.8 version of biber which needs the DEV 3.8 version of biblatex.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants