BBDB: Print birthdates

| bbdb, emacs

This snippet goes through all the records in my Big Brother Database,
prints out birthdate and a link to the record, and then sorts the

(defun sacha/bbdb-insert-birthdates ()
  "Insert a list of birthdates, sorted by month.
For best effect, dates should be of the form"
      (lambda (rec)
        (when (bbdb-record-getprop rec 'birthdate)
           (if (string-match "..\\...$" (bbdb-record-getprop rec 'birthdate))
               (match-string 0 (bbdb-record-getprop rec 'birthdate))
             (bbdb-record-getprop rec 'birthdate))
           " | "
            (concat "bbdb://"
                     " " "." (bbdb-record-name rec)))
            (bbdb-record-name rec))
     (sort-lines nil (point-min) (point-max))

Random Emacs symbol: find-tag-noselect – Command: Find tag (in current tags table) whose name contains TAGNAME.

You can comment with Disqus or you can e-mail me at