Take the 2-minute tour ×
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.

I am using the natbib package in a collaborative (which means I can't jettison the use of natbib entirely) document. I want to get citations in numeric form in both the text and bibliography, i.e I'd like a reference to Jones et al to appear as [15] in the text and [15] Jones et al ... in the bibliography.

Using the numbers option to natbib gets me the former, but with the plainnat or abbrvnat bibliography style I'm unable to get the latter. In fact I have to use abbrv and deal with some minor warnings. While I can get what I want to work, I'm wondering if I'm just not doing the right thing to get the desired behavior without kludging.

Update: In response to the comment, I tried to create an MWE, and realized that the problem is possibly coming from a different source. This is part of a grant proposal, and so the references need to be separated from the main text. So the original document called a.tex contains

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

\begin{document}
\citep{something}

\bibliographystyle{plainnat}
\bibliography{bibfile.bib}
\end{document}

and the file references.tex contained

\documentclass{article}

\begin{document}
\input{a.bbl}   
\end{document} 

If I compile a.tex directly to PDF, the referencing works fine. But if I compile it, and then compile references.tex to PDF, I get an author-year bibliography listing in references.pdf.

I'll reiterate that there are other ways to do this (for example, I use the pdfpages package in my own documents to strip out the references). But for now I'm stuck with this setup, so I'd like to solve the problem with minimal change in workflow.

share|improve this question
    
It is strange. I have no problem using natbib with the numbers option and abbrvnat. Could you post a MWE? –  Michael Ummels Mar 21 '11 at 7:59
    
@Michael I've added the MWE, and it yields some surprising things. –  Suresh Mar 21 '11 at 8:38
4  
@Suresh: You need natbib in both documents: the way it works means that the labels are generated by LaTeX and are not part of the .bbl file. –  Joseph Wright Mar 21 '11 at 8:58
    
excellent. that fixes it. If you made it an answer I can accept it. –  Suresh Mar 21 '11 at 18:00
    
@Joseph: Please convert your comment into an answer. –  lockstep Apr 15 '11 at 17:25
show 1 more comment

1 Answer

up vote 3 down vote accepted

You need natbib in both documents: the way it works means that the labels are generated by LaTeX and are not part of the .bbl file.

share|improve this answer
add comment

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.