0

the guidelines for my university paper want citation like this:

Within the text:

1 author: Johnson (2018) states that... or "blahblah" (Johnson 2018).

2 authors: Johnson/Smith (2017) mention ... or "blabla" (Johnson/Smith 2017).

more authors: Johnson et al. (2019) ... or "blabla" (Johnson et al. 2019).

Scenario 1 and 3 work fine for me, but when using 2 authors, Biblatex is sparating with "and" (Johnson and Smith (2017)) instead of the slash I want.

Is there a way to renew the command?

In the bibliography, the "and" should stay, because there the guidelines require it.

Thanks for the help!

Edit: the package settings and used commands look like this:

\usepackage[style=authoryear,maxcitenames=2,maxbibnames=99]{biblatex}
\DefineBibliographyStrings{ngerman}{ 
   andothers = {{et\,al\adddot}},             
} 
\DeclareNameAlias{sortname}{last-first}
2

One can change the name delimiter just for the document body and retain the original definition for the bibliography:

\documentclass{article}


\usepackage[style=authoryear,maxcitenames=2,maxbibnames=99]{biblatex}
\DefineBibliographyStrings{ngerman}{ 
   andothers = {{et\,al\adddot}},             
} 
\DeclareNameAlias{sortname}{last-first}


\addbibresource{biblatex-examples.bib}



\begin{document}
\begingroup
\renewcommand*{\finalnamedelim}{/}
\renewcommand*{\multinamedelim}{/}

normal document text

\cite{sigfridsson}


\endgroup
\printbibliography
\end{document}

enter image description here

  • Unfortunatly, that does not work for me. Neither with \textcite nor with \cite or \parencite. – spqx Jul 1 at 11:39
  • @spqx That's not very helpful information. Can you make a document that shows how it is not working for you? – user191948 Jul 1 at 11:40
  • I got the "/" to work, I hat to paste the renowcommands after my \begintitling and \endtitling-environment. Another problem occured: Instead of Sigfridson/Ryde it shows E. Sigfridson/U. Ryde. Any idea how to fix it? – spqx Jul 1 at 12:50
  • With a current system you could use the context-sensitive \DeclareDelimFormat instead of grouped \renewcommands. Unfortunately, the default set-up means that this will require some code duplication... – moewe Jul 1 at 16:02
0

With more recent versions of biblatex I recommend you use that multinamdelim and finalnamedelim are context-sensitive delimiters that can be redefine with \DeclareDelimFormat.

Unfortunately, the defaults are so that the safest definition involves copying the original definition, which means that the code is a bit longer than in user191948's answer

\documentclass{article}
\usepackage[style=authoryear,maxcitenames=2,maxbibnames=99]{biblatex}
\DefineBibliographyStrings{ngerman}{
   andothers = {{et\,al\adddot}},
}

\DeclareNameAlias{sortname}{family-given}

\DeclareDelimFormat{multinamedelim}{\addslash}
\DeclareDelimAlias{finalnamedelim}{multinamedelim}

\DeclareDelimFormat[bib]{multinamedelim}{\addcomma\space}
\DeclareDelimFormat[bib]{finalnamedelim}{%
  \ifnumgreater{\value{liststop}}{2}{\finalandcomma}{}%
  \addspace\bibstring{and}\space}

\addbibresource{biblatex-examples.bib}

\begin{document}
\cite{sigfridsson}

\printbibliography
\end{document}

Sigfridsson/Ryde 1998//Sigfridsson, Emma and Ryde, Ulf (1998). “Comparison of methods for deriving atomic charges from the electrostatic potential and moments”. In: Journal of Computational Chemistry 19.4, pp. 377–395. doi: 10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.