29

I am following the biblatex in a nutshell (for beginners) and meet this error during compiling BiBTeX:

This is BibTeX, Version 0.99d (MiKTeX 2.9.6500) The top-level auxiliary file: test.aux I found no \citation commands---while reading file test.aux I found no \bibdata command---while reading file test.aux I found no \bibstyle command---while reading file test.aux (There were 3 error messages)

I find no \citation, \bibdata or \bibstyle command in my script as suggested from TeXmaker. Do you know what's wrong? The code is:

\documentclass{article}
\usepackage{biblatex}
\bibliography{References}

\begin{document} test test\cite{dym_fourier_1972} \printbibliography \end{document}

I find this (duplicate?) question but I don't understand it: No \citation, \bibdata, \bibstyle commands

Ooker
  • 1,450
  • 1
  • 12
  • 26
  • 4
    biblatex defaults to biber not bibtex as the program to use (there is a backend=bibtex option if you need bibtex) – David Carlisle Dec 14 '17 at 17:44
  • 2
    If you use biblatex, the \bibliography command is deprecated. You really should write \addbibresource{References.bib}. Note that the filename extension (here: .bib) must be provided when using \addbibresource to specify the bib file. – Mico Dec 14 '17 at 17:57
  • 1
    You have to run biber, not bibtex. – egreg Dec 14 '17 at 18:07
  • 3
    You need to run Biber, but you are running BIbTeX. Have a look at Biblatex with Biber: Configuring my editor to avoid undefined citations and Troubleshooting for biber. – moewe Dec 14 '17 at 19:49
  • Did you get anywhere running Biber? – moewe Dec 15 '17 at 09:47
  • 1
    Would you agree that in essence your question is a duplicate of https://tex.stackexchange.com/q/154751/35864? – moewe Dec 15 '17 at 11:06
  • @moewe well, largely overlapped I'd say. The solution is the same, but it isn't in the top answers when I googled the error – Ooker Dec 15 '17 at 11:15
  • 1
    Yes, but even when the question here is marked as a duplicate it remains searchable. And since the solution is exactly the same, I think that would be the right course of action. – moewe Dec 15 '17 at 11:38
  • @moewe well, I did read it, but it wasn't enough for me to really understand how to successfully make bibliography in LaTeX. That question is more about how to compile it, with an assumption that the readers have already understood the concepts. I was stuck on the convolution of the concepts, so answers should stress it first – Ooker Dec 15 '17 at 12:46

2 Answers2

45

There are two engines to read .bib files:

  • BibTex. This is the old one and is the default engine used by TeXmaker
  • Biber. This is the new engine and is used in my example

I find there are three sources of confusion that newcomers of Biber may have:

  • The file .bib is commonly called as a "bibtex" file, but it's an inherited name from the old engine, and should be perceived as having no relation to the BibTeX engine now
  • Commands intended to be used by BibTeX can be used by Biber, thanks to the biblatex package for supporting both engines
  • Biber, BibTex, biblatex... bi bi bi (ಠ_ಠ)

You can read more on the history here.

Here is how to fix this:

1. Make sure the editor running Biber, not BibTeX

For TeXmaker:

For other editors, see: Biblatex with Biber: Configuring my editor to avoid undefined citations.

2. Run LaTeX → Biber → LaTeX

Make sure you use Biber commands to print bibliography:

  • \usepackage{biblatex}
  • \addbibresource{filename.bib}
  • \printbibliography

Do not use \bibliography or \bibliographystyle as they belong to BibTeX.

Read more: Getting Started with Biblatex

Ooker
  • 1,450
  • 1
  • 12
  • 26
  • I was still getting these errors and finally figured out that I somehow have things configured to run both biber and bibtex. It seems that superfluously running bibtex is harmless (apart from scaring you with harmless errors). – Marten Mar 20 '23 at 11:41
  • Make sure if you use TexStudio in the Compile option that Default bibliography tool is Biber (roughly translating it back to English). – Gresthol May 28 '23 at 18:44
4

If you are using LaTeX-Workshop on Visual Studio Code and you have set biber as Biblatex backend in your .tex file

\usepackage[backend=biber]{biblatex}

and still see errors in VSCode "Problems" tab such as

I found no \citation commands BibTeX
I found no \bibdata command BibTeX
I found no \bibstyle command BibTeX

it might be that you still have Latex-workshop › Intellisense › Citation: Backend set to bibtex in VSCode preferences and haven't overwritten it, either globally by choosing biblatex (that will then use biber) in VSCode preferences, or locally (which is IMO the best option if you share your work with others) by writing a .vscode/settings.jsonfile in which you set at least this option:

{
  "latex-workshop.intellisense.citation.backend": "biblatex",
  // (in this file you may have also configured outdir, recipes and tools)
  "latex-workshop.latex.outDir": "%DIR%/build/",
  "latex-workshop.latex.recipes": [
    {
      "name": "latexmk",
      "tools": ["latexmk"]
    },
    {
      "name": "pdflatex -> biber -> pdflatex*2",
      "tools": ["pdflatex", "biber", "pdflatex", "pdflatex"]
    }
  ],
  "latex-workshop.latex.tools": [
    {
      "name": "latexmk",
      "command": "latexmk",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        "-pdf",
        "-outdir=%OUTDIR%",
        "%DOC%"
      ],
      "env": {}
    },
    {
      "name": "pdflatex",
      "command": "pdflatex",
      "args": [
        "-synctex=1",
        "-interaction=nonstopmode",
        "-file-line-error",
        "-outdir=%OUTDIR%",
        "%DOC%"
      ],
      "env": {}
    },
    {
      "name": "biber",
      "command": "biber",
      "args": ["--output-directory=%OUTDIR%", "%DOCFILE%"],
      "env": {}
    },
  ]
}
Zitoun
  • 141