1

Does cited articles/books in JabRef add all of the references to bibliography in LaTeX even though you did not cite them in the thesis? Because I have one JabRef file and I want to add bibliography to end of the each chapter, but it adds all of the references to the each chapters.

  • 6
    Jabref is just a graphical interface to manage your database (the .bib file). Then when you call bibtex on a specific document, it looks for the cited references in the .bib file. To understand why all the references are included in your case, we would need a minimal working example. Are you using \nocite{*} anywhere? – Corentin Sep 10 '13 at 23:46
  • i use \citep{...} – tevzia Sep 10 '13 at 23:47
7

It seems that you want chapterwise bibliographies.

This can be done with bibunits which works together with natbib. Just put \putbib where you want the chapter bibliography and add the following to the preamble.

\let\stdthebibliography\thebibliography
\renewcommand{\thebibliography}{%
  \let\section\subsection
  \stdthebibliography}

\bibliographyunit[\section]
\bibliography*{\jobname}
\bibliographystyle*{plainnat}

This makes sure that you can use \putbib in the \sections; \bibliography*{\jobname} specifies the .bib source file while \bibliographystyle*{plainnat} specifies the bibliography style (.bst file)

\documentclass[american]{article}
\usepackage{babel}
\usepackage{natbib}
\usepackage{bibunits}

\let\stdthebibliography\thebibliography
\renewcommand{\thebibliography}{%
  \let\section\subsection
  \stdthebibliography}

\bibliographyunit[\section]
\bibliography*{\jobname}
\bibliographystyle*{plainnat}

\begin{filecontents}{\jobname.bib}
@article{testart,
  author        = {Arnold Uthor and William Riter},
  title         = {A Very Interesting Article},
  journal       = {Journal of Articles},
  volume        = {7},
  number        = {3},
  pages         = {1-5},
  year          = {2010},
}
@book{testbookt,
  author        = {Arnold Uthor},
  title         = {Long Book},
  date          = {1990},
}
@book{testbook,
  author        = {Walter Ordsmith},
  editor        = {Eddie Ditor},
  title         = {The Work},
  subtitle      = {Subtitle},
  year          = {1983},
}
@online{testonline,
  author        = {Bernie Logger},
  title         = {A Very Opinionated Blog Post},
  url           = {http://example.com},
  year          = {2013},
}
\end{filecontents}

\begin{document}
  \section{First section}
    some text \citep{testart} more text more citations
    \putbib

  \section{Second section}
    some text \citep{testonline} more text more citations
    \putbib

\end{document}

enter image description here


You can also use biblatex, biblatex has a natbib compatibility mode (see § 3.7.9, p.88, of the documentation). For more about multiple bibliographies, see §3.6.4 and 3.11.3 of the biblatex documentation. Put this in your preamble

\usepackage[style=authoryear,backend=biber,natbib,refsection=section]{biblatex}
\addbibresource{\jobname.bib}

but do not load natbib or other citation packages. With refsection=section every \section is a refsection in its own right, so you can put \printbibliography[heading=subbibliography] where you want the bibliography for that particluar section to go.

\documentclass[american]{article}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[style=authoryear,backend=biber,natbib,refsection=section]{biblatex}
\addbibresource{\jobname.bib}

\begin{filecontents}{\jobname.bib}
@article{testart,
  author        = {Arnold Uthor and William Riter},
  title         = {A Very Interesting Article},
  journal       = {Journal of Articles},
  volume        = {7},
  number        = {3},
  pages         = {1-5},
  year          = {2010},
}
@book{testbookt,
  author        = {Arnold Uthor},
  title         = {Long Book},
  date          = {1990},
}
@book{testbook,
  author        = {Walter Ordsmith},
  editor        = {Eddie Ditor},
  title         = {The Work},
  subtitle      = {Subtitle},
  year          = {1983},
}
@online{testonline,
  author        = {Bernie Logger},
  title         = {A Very Opinionated Blog Post},
  url           = {http://example.com},
  year          = {2013},
}
\end{filecontents}

\begin{document}
  \section{First section}
    some text \citep{testart} more text more citations
    \printbibliography[heading=subbibliography]

  \section{Second section}
    some text \citep{testonline} more text more citations
    \printbibliography[heading=subbibliography]
\end{document}

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.