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've just been revisiting bibliographies, and trying to manage them with Jabref. I seem to have found something wrong with @strings (or my understanding of them). In my pre-Jabref .bib file, I have:

@string{pok = "Poughkeepsie, NY"}
@Manual{dxcapa24,
  ...
  location    = pok,
  ...
}

which in my .bbl file becomes, by courtesy of biber and BibLaTeX,

\list{location}{1}{%
  {Poughkeepsie, NY}%
  }

Now, after Jabref, my .bib file looks like this:

@STRING{pok = {Poughkeepsie, NY}}
@MANUAL{dxcapa24,
  ...
  location = {#pok#},
  ...
}

which fails to expand correctly in my .bbl file, causing a LaTeX error when it gets imbedded:

\list{location}{1}{%
    {#pok#}%
    }

My questions are:

  • Am I doing something wrong and if so, how do I correct it?
  • Where is the definitive @string syntax and semantics reference for .bib files?
  • Is there a problem with Jabref and/or biber?

Note: I haven't provided a full MWE, as I believe the snippets fully illustrate the problem; but I'll be happy to provide one if the snippets are thought inadequate.


Update:

From the BibTeX website:

When quotation-marks are used, string concatenation using # is possible, but not when braces are used.

Which suggests that Jabref might be in error. A view has also been exposed in the SF Jabref forums that Jabref itself should convert @strings to their expanded values, with another, Jabref-specific, mechanism for handling abbreviations which removes the need for biber to do this. Not sure I'm entirely happy with that, though.


Thanks to @Fran for reminding me: in my case, shorttitle is also messed up, while author, title, and publisher are handled correctly.


@Fran's answer solves the problem. I apologise for any premature aspersions on Jabref.

share|improve this question
1  
It should be location=pok, AFAIK. If JabRef writes out location={#pok#} then it's doing an utterly wrong thing. BibTeX doesn't do string substitutions in braced (or doubly quoted) fields and I believe Biber is the same. –  egreg Jan 26 '13 at 14:01
    
@egreg : That was rather what I felt, though I was a bit hesitant to call bug on jabref. –  Brent.Longborough Jan 26 '13 at 14:13
    
Seem a problem with field location only: in address or editor fields the entry #pok# is saved correctly as pok without {}. –  Fran Jan 26 '13 at 18:03
add comment

1 Answer

up vote 6 down vote accepted

In menu Options -> Preferences -> File ->

Select the radio button "Resolve strings for all fields except:" instead of "Resolve strings for standard BibTeX fields only".

share|improve this answer
    
Many thanks, indeed! –  Brent.Longborough Jan 26 '13 at 22:29
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.