1

I have oceanbib.bib:

%% This BibTeX bibliography file was created using BibDesk.
%% http://bibdesk.sourceforge.net/
%% Saved with string encoding Unicode (UTF-8) 
@article{essd-7-47-2015,
    Author = {Le Qu\'er\'e, C. and Moriarty, R. and Andrew, R. M. and Peters, G. P. and Ciais, P. and Friedlingstein, P. and Jones, S. D. and Sitch, S. and Tans, P. and Arneth, A. and Boden, T. A. and Bopp, L. and Bozec, Y. and Canadell, J. G. and Chini, L. P. and Chevallier, F. and Cosca, C. E. and Harris, I. and Hoppema, M. and Houghton, R. A. and House, J. I. and Jain, A. K. and Johannessen, T. and Kato, E. and Keeling, R. F. and Kitidis, V. and Klein Goldewijk, K. and Koven, C. and Landa, C. S. and Landsch\"utzer, P. and Lenton, A. and Lima, I. D. and Marland, G. and Mathis, J. T. and Metzl, N. and Nojiri, Y. and Olsen, A. and Ono, T. and Peng, S. and Peters, W. and Pfeil, B. and Poulter, B. and Raupach, M. R. and Regnier, P. and R\"odenbeck, C. and Saito, S. and Salisbury, J. E. and Schuster, U. and Schwinger, J. and S\'ef\'erian, R. and Segschneider, J. and Steinhoff, T. and Stocker, B. D. and Sutton, A. J. and Takahashi, T. and Tilbrook, B. and van der Werf, G. R. and Viovy, N. and Wang, Y.-P. and Wanninkhof, R. and Wiltshire, A. and Zeng, N.},
    Date-Added = {2016-01-11 15:29:55 +0000},
    Date-Modified = {2016-01-11 15:29:55 +0000},
    Doi = {10.5194/essd-7-47-2015},
    Journal = {Earth System Science Data},
    Number = {1},
    Pages = {47--85},
    Title = {Global carbon budget 2014},
    Url = {http://www.earth-syst-sci-data.net/7/47/2015/},
    Volume = {7},
    Year = {2015},
    Bdsk-Url-1 = {http://www.earth-syst-sci-data.net/7/47/2015/},
    Bdsk-Url-2 = {http://dx.doi.org/10.5194/essd-7-47-2015}}

In the same directory as my latex file:

\documentclass[os, article]{copernicus}

\usepackage{cite}

\begin{document}

\title{text}



\Author[1]{my}{name}


\affil[1]{University}


\runningtitle{title}

\runningauthor{my name}

\correspondence{my email)}



\received{}
\pubdiscuss{} %% only important for two-stage journals
\revised{}
\accepted{}
\published{}




\firstpage{1}

\maketitle



\begin{abstract}
I will fill in the abstract text later on..
\end{abstract}



\introduction  %% \introduction[modified heading if necessary]

\upshape{ text \cite{essd-7-47-2015}}


%% REFERENCES

%% The reference list is compiled as follows:


% I don't know what to do with this!!

%\begin{thebibliography}{}
%
%\bibitem[AUTHOR(YEAR)]{LABEL}
%REFERENCE 1
%
%\bibitem[AUTHOR(YEAR)]{LABEL}
%REFERENCE 2
%
%
%\end{thebibliography}


%% authors experienced with BibTeX only have to include the following two lines:
%%
 \bibliographystyle{copernicus}
 \bibliography{oceanbib} % my bib file in same directory



%% LITERATURE CITATIONS
%%
%% command                        & example result
%% \citet{jones90}|               & Jones et al. (1990)
%% \citep{jones90}|               & (Jones et al., 1990)
%% \citep{jones90,jones93}|       & (Jones et al., 1990, 1993)
%% \citep[p.~32]{jones90}|        & (Jones et al., 1990, p.~32)
%% \citep[e.g.,][]{jones90}|      & (e.g., Jones et al., 1990)
%% \citep[e.g.,][p.~32]{jones90}| & (e.g., Jones et al., 1990, p.~32)
%% \citeauthor{jones90}|          & Jones et al.
%% \citeyear{jones90}|            & 1990




\end{document}

Why am I getting errors such as:

Package natbib warning: Citation 'essd-7-47-2015' on page n undefined input

when running latex typeset on the line of \cite

and when running bibtex typesetting:

found no \citation, \bbdata, and \bibstyle commands in the .aux file

Can anyone help me!?!

cheers in advance!

  • 1
    I changed \Author to \author and added a \conclusions section as required. If I run BibTeX and then LaTeX again, I get the expected result. You shouldn't load the cite package anyhow. – egreg Jan 11 '16 at 17:34
2

I saved your file in a directory where I have the copernicus class as michael.tex and also oceanbib.bib. I did some changes:

  • Removed the inexistent article option
  • Fixed \Author[1]{my}{name} into \author[1]{my name}
  • Removed \usepackage{cite} that's incompatible with natbib (loaded by the class)
  • Added a \conclusions section as required by the template.
\documentclass[os]{copernicus}

\begin{document}

\title{text}
\author[1]{my name}
\affil[1]{University}

\runningtitle{title}
\runningauthor{my name}
\correspondence{my email)}
\received{}
\pubdiscuss{} %% only important for two-stage journals
\revised{}
\accepted{}
\published{}

\firstpage{1}

\maketitle

\begin{abstract}
I will fill in the abstract text later on..
\end{abstract}

\introduction  %% \introduction[modified heading if necessary]

text \cite{essd-7-47-2015}

\conclusions

zzz

\bibliographystyle{copernicus}
\bibliography{oceanbib} % my bib file in same directory

\end{document}

Then I did

pdflatex michael
bibtex michael
pdflatex michael
pdflatex michael

After this, the output is as expected:

enter image description here

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.