28

I need to cite something for which only an approximate date is known i.e. 'circa YYYY'. Normally, I would write this as 'cYYYY'. However, if I try putting this in the date field of my .bib entry, (I just discovered rather too late that...) I get no date at all. What is the correct way to handle such cases?

If I use the year field rather than date, the output is correct, but I'm not sure whether this is the right way to handle such cases given that year etc. are provided primarily for backwards compatibility.

dateless entry

\documentclass{article}
\usepackage{biblatex}
\begin{filecontents}{\jobname.bib}
  @book{mybook,
    author      =   {Author, A. N.},
    date        =   {c1550},
    title       =   {Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
\end{filecontents}
\bibliography{\jobname}
\begin{document}
  \fullcite{mybook}
\end{document}

EDIT

Setting aside the question of whether the use of year is deprecated or intended for this kind of case, one reason that simply using year is not a satisfactory solution is precisely because BibLaTeX does not parse it very intelligently. Consider the following example:

\documentclass{article}
\usepackage[style=authoryear]{biblatex}
\begin{filecontents}{\jobname.bib}
  @book{book,
    author      =   {Author, A. N.},
    year        =   {c1550},
    title       =   {Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{prequel,
    author      =   {Author, A. N.},
    date        =   {1540},
    title       =   {Early Tudor Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{sequel,
    author      =   {Author, A. N.},
    year        =   {c1560},
    title       =   {Earlier Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{afterthought,
    author      =   {Author, A. N.},
    date        =   {1570},
    title       =   {Greatest Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
\end{filecontents}
\bibliography{\jobname}
\begin{document}
  \nocite{*}
  \printbibliography
\end{document}

The entries here should be sorted in date order, but they are not:

unsorted dates

3
  • 4
    It's a good question. Commented Jan 23, 2015 at 20:34
  • @GonzaloMedina I thought I must be missing something in the manual but I looked through every table of date formats I could find to no avail. Surprisingly, I couldn't find a question here about it either. (Doesn't mean there isn't one, of course.)
    – cfr
    Commented Jan 23, 2015 at 21:55
  • (Summing up earlier comments:) One non-solution / workaround is to use the 'literal' field year and sortyear.
    – jon
    Commented Jan 24, 2015 at 1:52

2 Answers 2

17

In my opinion year is the right field.

Apart from my opinion, if you want your "circa " years to be computed as normal ones by the sorting processor, add the following lines in your preamble:

\DeclareSourcemap{
  \maps[datatype=bibtex]{
      \map[overwrite=false]{
          \step[fieldsource=year]
          \step[fieldset=sortyear, origfieldval, final]
          \step[fieldsource=sortyear, match={c}, replace={}]
    }
  }
}

This lets the processor think that the c preceeding the year is not there...

MWE (used \addbibresource{\jobname.bib} instead of \bibliography{\jobname})

\documentclass{article}
\usepackage[style=authoryear]{biblatex}
\begin{filecontents}{\jobname.bib}
  @book{book,
    author      =   {Author, A. N.},
    year        =   {c1550},
    title       =   {Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{prequel,
    author      =   {Author, A. N.},
    date        =   {1540},
    title       =   {Early Tudor Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{sequel,
    author      =   {Author, A. N.},
    year        =   {c1560},
    title       =   {Earlier Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{afterthought,
    author      =   {Author, A. N.},
    date        =   {1570},
    title       =   {Greatest Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
\end{filecontents}

\DeclareSourcemap{
  \maps[datatype=bibtex]{
      \map[overwrite=false]{
          \step[fieldsource=year]
          \step[fieldset=sortyear, origfieldval, final]
          \step[fieldsource=sortyear, match={c}, replace={}]
    }
  }
}


\addbibresource{\jobname.bib}

\begin{document}
  \nocite{*}
  \printbibliography
\end{document}  

Output

enter image description here

3
  • (+1) Thanks for the sorting code, especially. The year solution I think is a workaround rather than really a 'right' way to do it, in that it is using something which seems to be considered deprecated by the author. Maybe Jon is right and the best solution would be to get the developers to recognise year as a BibLaTeX field, so to speak, proper, rather than just something used for backwards compatibility....
    – cfr
    Commented Jan 24, 2015 at 11:06
  • @cfr Why do you say that year is there only for backwards compatibility? Commented Jan 24, 2015 at 11:18
  • That seems to be what the documentation says.... Is there somewhere in the manual which suggests otherwise? E.g. pp 35. year is a standard field in the data interface (where data from date gets mapped, too), but the manual indicates that it is intended for backwards compatibility in .bib files. (And it doesn't indicate any other intended use for the .bib field.)
    – cfr
    Commented Jan 24, 2015 at 11:20
16

It's now possible to handle approximate dates with biblatex 3.5. According to the documentation (§2.3.8, p. 36) and the example file 96-dates.tex, you can use the date field writing date = {1550~}

\documentclass{article}
\usepackage[style=authoryear, 
    datecirca=true,
    ]{biblatex}
\begin{filecontents}{\jobname.bib}
  @book{book,
    author      =   {Author, A. N.},
    date        =   {1550~},
    title       =   {Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{prequel,
    author      =   {Author, A. N.},
    date        =   {1540},
    title       =   {Early Tudor Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{sequel,
    author      =   {Author, A. N.},
    date        =   {1560~},
    title       =   {Earlier Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
  @book{afterthought,
    author      =   {Author, A. N.},
    date        =   {1570},
    title       =   {Greatest Elizabethan Escapes},
    publisher   =   {Quills \& Offspring},
    location    =   {Hamlet, British Isles}}
\end{filecontents}
\bibliography{\jobname}
\begin{document}
  \nocite{*}
  \printbibliography
\end{document}

Whit the following result:

enter image description here

Edit for styling customization:

Adding the two following lines in the preamble (see documentation §3.10.1, pp. 108-109):

\renewcommand{\datecircadelim}{}
\DefineBibliographyStrings{english}{circa = c}

enter image description here

3
  • Thanks. I noticed this, although I've not yet used it. I assume it is possible to customise the circa string and format, so I must look into it.
    – cfr
    Commented Jan 20, 2017 at 23:51
  • I would be interested if you or someone find how to customize it, because I'm french speaking and it's not localized. I will search too.
    – poch
    Commented Jan 21, 2017 at 9:11
  • If the current french.lbx gives incorrect output for French dates, you might want to swing by the biblatex bug tracker (github.com/plk/biblatex/issues) and inform the developers.
    – moewe
    Commented Jan 21, 2017 at 12:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .