% This is an example document accompanying "LaTeX for Administrative Work"
% See www.dickimaw-books.com/latex/admin/ for the book details,
% including licence.
% arara: pdflatex
% arara: bibtex
% arara: pdflatex
% arara: pdflatex
\documentclass[helvetica,narrow,a4paper]{europecv}

\usepackage[T1]{fontenc}
\usepackage{graphicx}
\usepackage{databib}

% personal data
\ecvname{Parrot, Polly}
\ecvaddress{42 The Lane, Some Town, Noshire AB1 2XY, United Kingdom}
\ecvtelephone[0712345678]{0123456789}
\ecvemail{polly.parrot@example.com}
\ecvnationality{British}
\ecvdateofbirth{1970-12-31}
\ecvgender{female}
\ecvpicture[width=2in]{me}% me.pdf image


% citation marker code:

\newcounter{refcount}
\newcommand*{\refmark}{\refstepcounter{refcount}[\therefcount]}

\newcommand*{\selectedpubs}{}

\begin{document}
\nocite{*}
\DTLloadbbl{mypubdata}{xampl}
\DTLifdbempty{mypubdata}
{}%
{%
  \DTLsort*{Year=descending,Month=descending}{mypubdata}
  \DTLforeachbibentry*{mypubdata}%
  {%
    \eappto\selectedpubs{\noexpand\ecvitem
      {\noexpand\DTLcustombibitem{\noexpand\refmark}{\noexpand\therefcount}{\DBIBcitekey}}% left text
      {\noexpand\DTLformatthisbibentry{mypubdata}{\DBIBcitekey}}% right text
    }%
    \ifnumless{\value{DTLbibrow}}{10}{}{\dtlbreak}%
  }%
}

 \begin{europecv}
  % display personal data:
  \ecvpersonalinfo
  % start a new section
  \ecvsection{Professional Positions}
  \ecvitem{1990--8}{Junior assistant at 
  ``Wibblies Avian Emporium''.}
  \ecvitem{1998--Present}{Senior assistant at
   ``The International Society of Duck and Geese Co-operation''.}
  % publications section
  \ecvsection{Selected Publications}
  \selectedpubs
 \end{europecv}

\end{document}
