1

The output from the code here is already quite close to the requirements I need to meet. However, there are two small things that are missing.

Currently the bibliography entry looks like: Simpson, Homer. Interview Bart Simpson. Springfield, 25/7/2018.

However, it should look like: Simpson, Homer. Interview Bart Simpson, 25/7/2018, Springfield.

So there are two things that need to be changed:

  1. add a comma after the interviewer not a point
  2. change location of date and address

With my very bumbling knowledge of biblatex I just tried to change the location of date and addres in the usebibmacro and to add \isdot to print a comma. Not very surprisingly both didn't work and unfortunately I also didn't find the answer to my questions in the biblatex manual (or to be more precise I didn't understand it).

So how do I have to change the code so it works?

    \RequirePackage{filecontents}
    \begin{filecontents*}{\jobname.bib}
    @interview{homer,
      interviewee = {Homer Simpson},
      interviewer = {Bart Simpson},
      date        = {2018-07-25},
      address     = {Springfield},
    }
    \end{filecontents*}


      \begin{filecontents}{interview.dbx}
      \DeclareDatamodelEntrytypes{interview}
       \DeclareDatamodelFields[type=list,datatype=name]{
        interviewer,
        interviewee,
      }

    \DeclareDatamodelEntryfields[interview]{
      addendum,
      doi,
      eprint,
      eprintclass,
      eprinttype,
      interviewer,
      interviewee,
      location,
      note,
      pubstate,
    }
    \end{filecontents}
    \documentclass[ngerman]{article}
    \usepackage{babel}
    \usepackage{csquotes}
    \usepackage[datamodel=interview,backend=biber]{biblatex}
    \usepackage{hyperref}
    \addbibresource{\jobname.bib}

    \NewBibliographyString{interview}
    \DefineBibliographyStrings{german}{%
      interview   = {Interview},
    }

    \DeclareNameAlias{interviewee}{author}

    \DeclareBibliographyDriver{interview}{%
      \usebibmacro{bibindex}%
      \usebibmacro{begentry}%
      \printnames{interviewee}%
      \newunit\newblock
      \bibstring{interview}%
      \setunit{\addspace}%
      \printnames{interviewer}%
      \newunit\newblock
      \printfield{note}%
      \newunit\newblock
      \usebibmacro{location+date}%
      \newunit\newblock
      \usebibmacro{doi+eprint+url}%
      \newunit\newblock
      \usebibmacro{addendum+pubstate}%
      \setunit{\bibpagerefpunct}\newblock
      \usebibmacro{pageref}%
      \newunit\newblock
      \iftoggle{bbx:related}
        {\usebibmacro{related:init}%
         \usebibmacro{related}}
        {}%
      \usebibmacro{finentry}}

    \begin{document}
    \cite{homer}

    \printbibliography
    \end{document}
3

Just tweaking the bibdriver from moewe's answer:

\RequirePackage{filecontents}
\begin{filecontents*}{\jobname.bib}
  @interview{homer,
    interviewee = {Homer Simpson},
    interviewer = {Bart Simpson},
    date        = {2018-07-25},
    address     = {Springfield},
  }
\end{filecontents*}


\begin{filecontents}{interview.dbx}
  \DeclareDatamodelEntrytypes{interview}
  \DeclareDatamodelFields[type=list,datatype=name]{
    interviewer,
    interviewee,
  }

  \DeclareDatamodelEntryfields[interview]{
    addendum,
    doi,
    eprint,
    eprintclass,
    eprinttype,
    interviewer,
    interviewee,
    location,
    note,
    pubstate,
  }
\end{filecontents}
\documentclass[ngerman]{article}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[datamodel=interview,backend=biber]{biblatex}
\usepackage{hyperref}
\addbibresource{\jobname.bib}

\NewBibliographyString{interview}
\DefineBibliographyStrings{german}{%
  interview   = {Interview},
}

\DeclareNameAlias{interviewee}{author}

\DeclareBibliographyDriver{interview}{%
  \usebibmacro{bibindex}%
  \usebibmacro{begentry}%
  \printnames{interviewee}%
  \newunit\newblock
  \bibstring{interview}%
  \setunit{\addspace}%
  \printnames{interviewer}%
  \setunit{\addcomma\space}%
  \usebibmacro{date}%
  \setunit{\addcomma\space}%
  \printlist{location}%
  \newunit\newblock
  \printfield{note}%
  \newunit\newblock
  \usebibmacro{doi+eprint+url}%
  \newunit\newblock
  \usebibmacro{addendum+pubstate}%
  \setunit{\bibpagerefpunct}\newblock
  \usebibmacro{pageref}%
  \newunit\newblock
  \iftoggle{bbx:related}
  {\usebibmacro{related:init}%
    \usebibmacro{related}}
  {}%
  \usebibmacro{finentry}}

\begin{document}
\cite{homer}

\printbibliography
\end{document}

enter image description here

  • And there I was thinking it would be clever to reuse location+date... – moewe Dec 16 '18 at 8:25
  • @moewe I guess this means you have a "style standardization bias" which is not always shared. ;-) – gusbrs Dec 16 '18 at 9:54

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.