[Tex/LaTex] How to not print the day/month of a BibLaTeX reference

biblatex

BibLaTeX seems to recommend1 the yyyy-mm-dd format for dates such as:

 date = {1989-03-12}

I have no objection to this format but I would like to be able to cite without printing the month and the day. With old BibTeX date fields, it was easy:

month = mar,
year = {1989},

So, I used to add \AtEveryBibitem{\clearfield{labelmonth}} to my .tex files.

How can I get rid of the month and the day with this new (BibLaTeX) format?

PS: I precise I cannot modify my .bib file.


1: BibLaTeX manual says : "If there is no date field
in an entry, biblatex will also consider the fields year and month for backwards
compatibility with traditional BibTeX." (p.34) which indicates that fields year and month are obsoletes with BibLaTeX.

Best Answer

There is a package option date for controlling this:

date=year, short, long, terse, comp, iso8601 default: comp This option controls the basic format of printed date specifications.

\documentclass{article}

\usepackage[date=year]{biblatex}
\addbibresource{\jobname.bib}

\begin{document}
\nocite{*}

\printbibliography

\end{document}

with database entry

@Article{Author,
  author =   {Author, A.},
  title =    {A paper},
  journal =  {J. Jour.},
  date =     {1989-03-12}
}

yields

Sample output