Well, in your code I can see some problems.
For example should package hyperref
be the last called package!
The documentation of package natbib
can you read by typing texdoc natbib
on your console/terminal. There are the styles listed you can use with natbib
and which styles and field names are supported.
To give you a starting point I changed your MWE, deleted not needed package calls for this problem, changed the order of package calls and added the missing informations for field year
and publisher
to your bib file (btw package filecontents
is only used to have bib file and TeX code in one compilable MWE).
MWE:
\RequirePackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@book{SMFC,
author = {{SMFC = Academia RPR, Institutul de lingvistica din Bucuresti}},
title = {Institutul de lingvistica din Bucuresti, Studii \c{s}i
materiale privitoare la formarea cuvintelor în limba român\u{a}},
note = {vol I, 1959 ; II, 1960 ; III, 1962 ; IV, 1967 ; V, 1969 ; VI, 1972},
year = {1972},
editor = {Editura Academiei},
publisher = {UNKNOWN},
volumes = {6},
location = {Bucarest},
}
@inbook{Asan-PsaltHur,
author = {Asan, Finuţa},
title = {Derivarea cu sufixe şi prefixe în Psaltirea Hurmuzaki},
booktitle = {SMFC},
year = {1959},
bookauthor = {Academia RPR, Institutul de lingvistica din Bucuresti},
editor = {Editura Academiei},
publisher = {UNKNOWN},
location = {Bucarest},
volume = {1},
volumes = {6},
pages = {203--212},
}
@book{Popescu-Formarea,
author = {Popescu Marin, Magdalena (coord.)},
title = {Formarea cuvintelor în limba română din secolele al XVI lea – al XVIII lea},
year = {2007},
editor = {Editura Academiei},
publisher = {UNKNOWN},
location = {Bucarest},
}
\end{filecontents*}
\documentclass[10pt,a4paper,final]{book}
\usepackage{fontspec} % utf-8 encoding!
\setmainfont{Times New Roman}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguages{english,german,latin,italian,spanish,russian,greek}
\usepackage[numbers]{natbib}
\usepackage[hidelinks]{hyperref}
\begin{document}
text \cite{Asan-PsaltHur} \nocite{*}
\section{Bibliographie}
\bibliographystyle{abbrvnat} % plainnat abbrvnat
\bibliography{\jobname}
\end{document}
Now if you compile you will get three warnings like this:
As you can see the warning is pretty clear (same with the warnings you got with your original code): you can not use author and editor both. Please rework your bib file. I also changed your undefined @mvbook
to @book
.
At last three tips:
SMFC = Academia RPR, Institutul de lingvistica din Bucuresti
is an unusual entry for an author, better would be to place the acronym in the text and use the complete name. But your given name for author is an institution, as I can see. So better use it as editor ...
Studii \c{s}i
should be in an utf-8 encoded file changed. Please change all tex substitutions for special characters with cedilie etc. to the corresponding original utf-8 letter.
- You need a field
year
to be style-conform, so in the case of your first entry SMFC
I would use field note={vol I, 1959 ; II, 1960 ; III, 1962 ; IV, 1967 ; V, 1969 ; VI, 1972},
instead your date field.
In your given code and bib file are several errors, for example the order of calling packages (hyperref
should be the last one in your case, or do not write ,,
in your bib entrys, ,
is needed ...).
Because I do not have your used class and style I changed them to class article
and style plainnat
and I added option numbers
to natbib
to get numbered bib entrys in your bibliography.
Please study my changes in the following MWE (package filecontents
is only used to have a compilable MWE with bib file and TeX code):
\RequirePackage{filecontents}
\begin{filecontents}{\jobname.bib}
@article{R1,
title = "A Guide to Latex",
journal = "Addison-Wesley",
volume = "1",
number = "1",
pages = "1 - 2",
year = "2003",
author = "Kopka H and Daly PW",
}
@article{R2,
title = "LaTeX: a Document Preparation System",
journal = "Addison-Wesley",
volume = "1",
number = "1",
pages = "1 - 2",
year = "1994",
author = "Lamport",
}
@article{R3,
title = "The LaTeX Companions",
journal = "Addison-Wesley",
volume = "1",
number = "1",
pages = "1 - 2",
year = "1994",
author = "Mittelbach F and Goossens M",
}
\end{filecontents}
\documentclass{article}%[Afour,sageh,times]{sagej}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{textcomp}
\usepackage{subcaption}
\usepackage{graphicx}
\usepackage{booktabs}
\usepackage{url}
\usepackage[numbers]{natbib}
\usepackage[%
colorlinks,bookmarksopen,bookmarksnumbered,citecolor=red,urlcolor=red
]{hyperref}
\newcommand\BibTeX{{\rmfamily B\kern-.05em \textsc{i\kern-.025em
b}\kern-.08em
T\kern-.1667em\lower.7ex\hbox{E}\kern-.125emX}}
\def\volumeyear{2016}
\begin{document}
\section{Introduction}
A very very very long introduction.
\section{Figure}
\begin{figure}[htb!]
\centering
\begin{subfigure}[t]{1\linewidth}
\centering
\includegraphics[scale=0.23,clip]{example-image-a}
\caption{f1 cap}
\label{fig:f1}
\end{subfigure}
\qquad
\begin{subfigure}[t]{1\linewidth}
\centering
\includegraphics[scale=0.21,clip]{example-image-b}
\caption{f2 cap}
\label{fig:f2}
\end{subfigure}
\caption{ f1 and f2}
\label{fig:f1f2}
\end{figure}
\section{Table}
\begin{table}[ht]
\small\sf\centering
\caption{abc\label{tab1}}
\begin{tabular}{llll}
\toprule
abc&a &b & c \\
\midrule
\texttt{1}&1 &1 & 1 \\
\texttt{2}&2 & 2 & 2\\
\texttt{3}&3 & 3 & 3 \\
\bottomrule
\end{tabular}\\[10pt]
\end{table}
Citing reference \cite{R1}, reference \cite{R2} and reference \cite{R3}.
\bibliographystyle{plainnat} % sageV
\bibliography{\jobname}
\end{document}
and the resulting pdf file:
Best Answer
When changing bibliography styles, it's usually a good idea to blow away the
.aux
file before recompiling with LaTeX, BibTeX, and LaTeX twice more. (This is especially true when switching from a style, such asplain
, that generates numeric-style citation call-outs to another style that generates authoryear-style call-outs.) In your case, the messages you get fromnatbib
after switching tonatdin
aren't so much error messages as they are warning messages. If you don't delete the aux files first, just hit "r" ("run") all three times when the warning messages are generated, and you'll end up with the correctly formatted entries in the references as well as the correct citation callout style.Incidentally, the configuration file that goes with the
natdin
bibliography style file contains the instructionThis instruction tells
natbib
to use round parentheses (cf the first two arguments) as well as authoryear-style call-outs (the fourth argument) for the citations. Hence, it's actually not necessary to specify the optionsround
andauthoryear
when loadingnatbib
. Of course, it doesn't hurt to specify the options anyway. It's just that\bibpunct
takes precedence over the options specified whennatbib
is loaded.Here's the output of a program that uses the
natdin
style:Just for comparison, here's the output of the same program when using the
plainnat
style --natbib
's re-implementation of the venerableplain
style -- instead (note thatplainnat
, unlikeplain
, can generate authoryear-style citation call-outs):