Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want to use the firstinits=true option of biblatex, and to disable the abbreviations for specific entries, I use {{authorname}}, as recommended in a previous question. However, biblatex is apparently unable to sort the bibliography in this case. No matter, I thought, I can just provide sortname for the few entries where this is necessary. But biblatex seems to ignore this, i.e. Baltasar appears first in my example.

\documentclass{article}
\usepackage{filecontents}
\usepackage[style=alphabetic,firstinits=true]{biblatex}

\begin{filecontents}{references.bib}
    @report{example1,
        author={Buthor, Baltasar},
        title={Baltie's report}
    }

    @report{example2,
        sortname={Author, Archibald},
        title={Archie's report},
        author={{Archibald Author}}
    }
\end{filecontents}
\bibliography{references.bib}

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

How do I use the sortname field properly?

Edit: I’m using an up-to-date TeXLive 2011, compiling with pdflatex and bibtex. Tried under both XP and Ubuntu.

share|improve this question
    
I compiled your example, and Archibald appears in the bibliography before Baltasar. –  user11171 Jan 26 '12 at 16:40
    
How do I add a comment to the question? I think my answer would have fit better as a comment. I am new to stack exchange. –  user11171 Jan 26 '12 at 16:42
    
Just use the link "add comment" below the question. –  Thorsten Jan 26 '12 at 17:08
1  
Use biber to get it working. No idea why ... –  Thorsten Jan 26 '12 at 17:34
1  
Sorting will in general work better with Biber. It has a far more complete and sophisticated sorting system, especially for tricky cases. –  PLK Jan 26 '12 at 19:44
show 2 more comments

1 Answer

up vote 6 down vote accepted

Adding sorting=nyt to the biblatex options will fix it:

\documentclass{article}
\usepackage{filecontents}
\usepackage[
    style=alphabetic,
    sorting=nyt,
    firstinits=true
]{biblatex}

\begin{filecontents}{references.bib}
  @report{example1,
    author={{Archibald Author}},
    title={Archies first report}
    }
  @report{example2,
    author={{Archibald Author}},
    sortname={Author, Archibald},
    title={Archies second report}
    } 
  @report{example3,
    author={Archibald Author},
    sortname={Author, Archibald},
    title={Archies third report}
    }
  @report{example4,
    author={Buthor, Baltasar},
    title={Balties report}
    }
  @report{example5,
    author={Cuthor, Charlie},
    title={Charlies report}
    }   
\end{filecontents}
\bibliography{references.bib}

\begin{document}
  % lorem~\cite{example2}
  \nocite{*}
  \printbibliography
\end{document}

See section 3.3.2 and section 3.1.2.1 of the biblatex documentation:
alphabetic: This style will set the following package options at load time: labelalpha=true, sorting=anyt.

anyt will sort by label, then name, then year, then title, which should be ok, as the label is also in alphabetic order, but for some reason (maybe a bug?) it does not work as expected.

share|improve this answer
    
Thanks, that works. In my version of the documentation it says: The style will set the following package options at load time: autocite=inline, labelalpha=true.. Anyway, seems a bit counter intuitive. –  Psirus Jan 26 '12 at 18:33
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.