TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

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?

share|improve this question
up vote 2 down vote accepted

You are mixing things.

If you want to use the plain bibliography style, load the natbib package. E.g.:

\documentclass{article}
\usepackage{natbib}

\begin{document}

\bibliographystyle{plainnat}

Some text \cite{GDP:2012}

\bibliography{summative}

\end{document}

If you want to use the APA style, then you can do to things: either use \bibliographystyle{apalike} with the natbib package or go like this:

\documentclass{article}
\usepackage{apacite}

\begin{document}

\bibliographystyle{apacite}

Some text \cite{GDP:2012}

\bibliography{summative}

\end{document}

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:

@misc{GDP:2012,
ALTauthor = {The World Bank},
ALTeditor = {},
title = {GDP Per Capita (Current \$US)},
year = {2012},
url = {http://data.worldbank.org/indicator/NY.GDP.PCAP.CD},
}

creates the following output:

enter image description here

For more information, please visit both the apacite package documentation and the natbib package documentation.

share|improve this answer
    
When I run it, I get (n.d) in my bibliography which I am assume means "no date" but I do have date and it is citing the title instead of the author. – Jeel Shah Apr 26 '13 at 18:31
    
Have you run it a couple of times? Which package are you using, natbib or apacite? – Mario S. E. Apr 26 '13 at 20:03
    
I am using the apacite package. I get the bibliography with the name and title and everything except the date. – Jeel Shah Apr 26 '13 at 20:07
    
please change your "data" entry to "year" in your .bib file and see what happens – Mario S. E. Apr 26 '13 at 20:13
    
I did that but it's not working. It still says (n.d). Is it working on your end? – Jeel Shah Apr 26 '13 at 20:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.
http://tex.stackexchange.com/questions/110913/issues-with-apacite-package-undefined-control-sequence-bibitem
tex.stackexchange.com
crawl=CC-MAIN-2016-26
80285
application/http; msgtype=response
sha1:KIPDZTZPPKWBLHKZ7FXPJUEHUAYVHKR2
<urn:uuid:2b7b10e2-5318-499b-bb58-6919153a91e1>
2016-07-02T02:14:22Z
151.101.1.69
sha1:5KWVEQOSGKCDPOHVVCRF2EYNNR3O6Y6F
<urn:uuid:f88ff46c-5f83-47f6-8844-7196e041c284>
http://tex.stackexchange.com/questions/110913/issues-with-apacite-package-undefined-control-sequence-bibitem
response
<urn:uuid:ccd9fde2-364d-40cc-9d2c-4ea541f876fd>
robots: classic
hostname: ip-10-164-35-72.ec2.internal
software: Nutch 1.6 (CC)/CC WarcExport 1.0
isPartOf: CC-MAIN-2016-26
operator: CommonCrawl Admin
description: Wide crawl of the web for June 2016
publisher: CommonCrawl
format: WARC File Format 1.0
conformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf