1

My bibliography codes looks like this

\usepackage[backend=biber,style=apa{biblatex}
\addbibresource{bibliographie.bib}

And an exemple of one my references

  @article{Harrison2007,
  title = {What's the Difference? Diversity Constructs as Separation, Variety, or Disparity in Organizations},
  volume = {32},
  issn = {0363-7425, 1930-3807},
  shorttitle = {What's the Difference?},
  language = {en},
  number = {4},
  journal = {Academy of Management Review},
  doi = {10.5465/amr.2007.26586096},
  author = {Harrison, David A. and Klein, Katherine J.},
  month = oct,
  year = {2007},
  pages = {1199-1228},
  file = {C:\\Users\\ornel\\Zotero\\storage\\RZNS5L26\\Harrison et Klein - 2007 - What's the difference diversity constructs as sep.pdf}

And I use this citation style

\autocite{Harrison2007}

But when I compile overleaf, the citation is not found.

This is the error I get : BibTeX Cannot find 'bibliographie.bib'!

Dosma
  • 41
  • Do any of your references appear correctly? Do just certain ones fail to be found? – Alan Munn Jul 20 '19 at 20:32
  • none of my references appear. It is like overleaf cannont read my bib files – Dosma Jul 20 '19 at 20:35
  • Do you get an error that says "bibtex cannot find bibliographie.bib"? – Alan Munn Jul 20 '19 at 20:37
  • If you scroll down past all the orange warnings, is there a red error message as in my previous comment? Have you tried deleting all the .aux files and then recompiling? (use the Trashcan icon in the error logs panel). – Alan Munn Jul 20 '19 at 20:44
  • Yes there is the error BibTeX Cannot find 'bibliographie.bib'! – Dosma Jul 20 '19 at 20:46
  • So that's the real error. It simply can't find your .bib file. So either the file is differently named, or at one point you had a typo in your \addbibresource line, and it hasn't updated properly. If that is the case, delete all the .aux files (which Overleaf calls cache files) and try again. But until that error is removed, the undefined references are irrelevant, since it can't find the file itself. – Alan Munn Jul 20 '19 at 20:50
  • I delete the cache, then copy paste the name of my bib files to be sure that I didn't do any typo but it still doesn't work. – Dosma Jul 20 '19 at 20:55
  • I'm trying to use biblatex but the message is bibtex , is that the issues ? – Dosma Jul 20 '19 at 21:08
  • No, that's just a generic error message generated by Overleaf; it should run biber automatically. I'm not really sure we can help you here. This seems like something you should take up with Overleaf support. – Alan Munn Jul 20 '19 at 21:10
  • Note that at least in the example posted here the entry Harrison2007 is missing the closing curly bracket and the end. This might just be a copy-and-paste error, but if it is not it can certainly cause Biber to get the hiccups and discard almost all entries from your .bib file. Other than that the entry looks OK and the rest of the code does not give any hints about problems apart from the possibly missing \DeclareLanguageMapping (which depends on code you haven't shown). We need to see a full MWE (https://tex.meta.stackexchange.com/q/228/35864) ... – moewe Jul 21 '19 at 09:32
  • ... and ideally the .log and .blg files. https://tex.stackexchange.com/q/462314/35864 shows how to download the .bbl file, use the same technique to download and inspect the .log and .blg files. – moewe Jul 21 '19 at 09:33

2 Answers2

2

Overleaf is running TeXLive 2017, which has an older version of biblatex-apa. In this version you need to add the following line to your preamble after you load biblatex (since you are writing in French).

\DeclareLanguageMapping{french}{french-apa}

The general syntax is:

\DeclareLanguageMapping{<lang>}{<lang>-apa}

If you are writing in English, you would usually use:

\DeclareLanguageMapping{english}{american-apa}

See Problem with \mkbibdateapalongextra of biblatex-apa for more detailed information.

If you had reported the log error, your question would have been easier to answer.

Alan Munn
  • 218,180
  • I'm not sure to understand how adding this line will help overleaf find my bib files. The error I have is Citation XXX on page XXX undefined on input line XXX – Dosma Jul 20 '19 at 20:22
  • I was working from the MWE posted in the answer by RedCloud. That example doesn't compile on Overleaf, so it seemed possible that this was your problem, and the line I give will fix it. (I assume it's already in your document then.) Does the sample code given by RedCloud work for you (with this addition)? There doesn't seem to be anything wrong with your .bib entry. – Alan Munn Jul 20 '19 at 20:28
  • Sadly, it doesn't work – Dosma Jul 20 '19 at 20:38
  • @Dosma Please be more helpful with your reports. "It doesn't work" provides no useful information for us to be able to help you. – Alan Munn Jul 20 '19 at 20:39
  • See also https://tex.stackexchange.com/q/474557/35864 – moewe Jul 21 '19 at 09:28
1

I cannot see any problem with the above bib entry:

\RequirePackage{filecontents}
\begin{filecontents*}{test.bib}
@article{Harrison2007,
    title = {What's the Difference? Diversity Constructs as Separation, Variety, or Disparity in 
    Organizations},
    volume = {32},
    issn = {0363-7425, 1930-3807},
    shorttitle = {What's the Difference?},
    language = {en},
    number = {4},
    journal = {Academy of Management Review},
    doi = {10.5465/amr.2007.26586096},
    author = {Harrison, David A. and Klein, Katherine J.},
    month = oct,
    year = {2007},
    pages = {1199-1228},
    file = {C:\\Users\\ornel\\Zotero\\storage\\RZNS5L26\\Harrison et Klein - 2007 - What's the difference 
    diversity constructs as sep.pdf},
}
\end{filecontents*}

\documentclass{report}
\usepackage[style=apa]{biblatex}
\addbibresource{test.bib}

\begin{document}

foo~\textcite{Harrison2007}
\printbibliography

\end{document} 

enter image description here

user187802
  • 16,850