TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to generate bibliography using bibtex. My problem is that keyword and is not generated to comma. I also want to put First name after Last name. (I'm using Gummi as LaTeX editor).



\usepackage[a4paper, left=25mm, right=25mm, top=25mm, bottom=25mm]{geometry}











author =        "Van Roy, P. and Haridi, S.",
title =         "Programowanie. Koncepcje, techniki i modele",
publisher =     "Wydawnictwo Helion",
year =          "2005",
address =       "Gliwice"

enter image description here

share|improve this question
Welcome to TeX.sx! Please add a minimal working example (MWE) that illustrates your problem. This just helps the community to get started on your problem, rather than recreating it from scratch. Also, it should show the \documentclass you're using, and related packages. – Werner Oct 10 '12 at 17:05
How would you like the reference to look like? – krlmlr Oct 18 '12 at 22:00

Customizing a standard bibliography style isn't easy. Normally you have to modify the code of the bst-file. This special language has a small introduction in the online documentation Tame the BeaST which is also via texdoc available. Next to the solution below I recommend the package biblatex which is more flexible. There is also a contribution of the standard styles How to emulate the traditional BibTeX styles (plain, abbrv, unsrt, alpha) as closely as possible with biblatex?

I will improve the styles soon

You are using the style plain which is defined in the file plain.bst. The location of the file can be found via the terminal command kpsewhich plain.bst. In my case it's:


Never touch the original file. So we need a copy of plain.bst in our working directory. I will call it myplain.bst. Now we can edit the file. Find the function FUNCTION {format.names} and replace the code by the following one:

FUNCTION {format.names}
{ 's :=
  #1 'nameptr :=
  s num.names$ 'numnames :=
  numnames 'namesleft :=
    { namesleft #0 > }
    { s nameptr "{ll}{, jj}{, ff}{~vv}" format.name$ 't :=
      nameptr #1 >
        { namesleft #1 >
            { ", " * t * }
            { numnames #2 >
                { "," * }
              t "others" =
                { " et~al." * }
                { ",~" * t * }
      nameptr #1 + 'nameptr :=
      namesleft #1 - 'namesleft :=

Inside your document you have to use \bibliographystyle{myplain} and you will get the output:

enter image description here

share|improve this answer

Your Answer


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.