I get the following errors when I try to cite with apacite
Undefined control sequence \bibitem{GDP:2012}
You can't use `\relax' after \the \bibitem{GDP:2012}
Citation `GDP:2012' undefined
There were undefined references.
Here is the MWE:
\documentclass{article}
\usepackage{apacite}
\begin{document}
\bibliographystyle{plain}
Some text \cite{GDP:2012}
\bibliography{summative}
\end{document}
and here is the BibTeX file
@online{GDP:2012,
ALTauthor = {The World Bank},
ALTeditor = {},
title = {GDP Per Capita (Current \$US)},
date = {2012},
url = {http://data.worldbank.org/indicator/NY.GDP.PCAP.CD},
}
Updated:
@misc{GDP:2012,
author = "The World Bank",
editor = {},
title = "GDP Per Capita (Current \$US)",
year = "2012",
url = "http://data.worldbank.org/indicator/NY.GDP.PCAP.CD",
}
I have ran it twice and the file is in the same directory as my .tex file. What could be the issue?
Best Answer
You are mixing things.
If you want to use the
plain
bibliography style, load thenatbib
package. E.g.:If you want to use the APA style, then you can do to things: either use
\bibliographystyle{apalike}
with thenatbib
package or go like this:Your .bib file is fine, but please keep in mind that for the
apacite
package, the entry @online is not supported, nor the "date" characteristic. However you can use @misc and "year".Using the second block of code, along with a refs.bib file looking like this:
creates the following output:
For more information, please visit both the apacite package documentation and the natbib package documentation.