I'd like to write a command so that for a particular record (found for example with (bbdb-search (bbdb-records) regexp)) I'm able to extract just the name part of it (or e. g. the mail part, or any part of the xfields). How would you lisp this?

  • I think you could use bbdb-search-prog with your own function as an argument. That function would need be called with a record looked up, and whenever you think that the record matches, it would need to return the record, in case it accepts it as a potential match. – wvxvw Sep 14 '15 at 10:30
  • Hi @wvxvw, sorry I was not clear enough. bbdb-search is just fine for me, no need for bbdb-search-prog. But I want to know how to extract for a found record for example the www part or the mail-alias... – Dieter.Wilhelm Sep 15 '15 at 15:37

There are accessor functions in bbdb3 for extracting certain part of the record:

(bbdb-record-name record)
(bbdb-record-firstname record)
(bbdb-record-lastname record)

They are defined in bbdb.el

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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