1

Using biber, I do not encounter this issue but I want to use bibtex for the backend option.

I have an "online" bibitem with an accessed on date but no publication date. I want the output to be along the lines of AUTHOR (n.d.) URL [Accessed on: dd/mm/year].

I can only find a way to do this by clearing the urlyear, which I don't want to do. Furthermore, this thread suggests setting the year to the text "n.d." however this generates a warning about issues with sorting which I would like to avoid.

MWE:

\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[style=authoryear, backend=biber, urldate=long, dateabbrev=false]{biblatex}

\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@online{appleby,
  author  = {Humphrey Appleby},
  date = {},
  title   = {On the Importance of the Civil Service},
  url     = {https://example.com/gov/sir-humphrey/importance-civil-service},
  urldate = {2018-08-23},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}
\nocite{*}
\printbibliography
\end{document}

enter image description here

I would like to display n.d. or similar in the empty brackets. I could do this either by:

  • Preventing the publication date being inherited from the access date.
  • Manually setting the date to be "null" somehow, but doing this it gives ("null") as the date in the ways that I have tried.

Thanks.

3

If you must use bibtex as your backend, then you can specify year = {nodate} instead of using the date field.

Aside: If you use biber as backend, then I think the easiest option is just to alter the definition of \DeclareLabeldate to remove urldate from the list of allowable fields. e.g.,

\DeclareLabeldate{%
  \field{date}
  \field{year}
  \field{eventdate}
  \field{origdate}
  \literal{nodate}
}

MWE using bibtex as backend

\documentclass[british]{article}
\usepackage{babel}
\usepackage{csquotes}

\usepackage[style=authoryear, backend=bibtex, urldate=long, dateabbrev=false]{biblatex}

\begin{filecontents}[overwrite]{\jobname.bib}
@online{appleby,
  author  = {Humphrey Appleby},
  year    = {nodate},
  title   = {On the Importance of the Civil Service},
  url     = {https://example.com/gov/sir-humphrey/importance-civil-service},
  urldate = {2018-08-23},
}
\end{filecontents}

\addbibresource{\jobname.bib}

\begin{document}
\nocite{*}
\printbibliography
\end{document}

MWE output

| improve this answer | |

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.