# Bibliography entries occasionally containing an extra comma

by hiccups   Last Updated September 11, 2019 15:23 PM - source

Occasionally, I am seeing extra commas being inserted in bibliography entries using natbib and the unsrtnat style. Why does this happen, and how can I fix this?

Here is a minimal example:

\begin{filecontents*}{bibliography.bib}
@misc{bib1,
title="{Title One}",
url="https://dummyurl"
}
@misc{bib2,
title="{Title Two}",
url="https://dummyurl"
}
\end{filecontents*}

\documentclass[]{article}
\usepackage[numbers]{natbib}
\begin{document}

This is a citation.~\cite{bib1}

%%This is another citation.~\cite{bib2} %% <--- if this line is uncommented, both bib entries will have an extra comma after the title

\bibliographystyle{unsrtnat}
\bibliography{bibliography}

\end{document}


Here is a screenshot of what I see: (left shows the output with the line in the MWE commented, right when it is uncommented)

Tags :

## biboptions not recognized

Updated March 29, 2015 07:07 AM