BibTeX key changed after I imported a bib file
I am new to Zotero, and have just imported my BibTeX file containing over 2000 references into Zotero.
After making some changes, I exported back from Zotero to BibTeX. Strangely, I noticed that all citation-keys have changed! For example, instead of yoon2008participatory, I have yoon_participatory_2008.
I do not care much about the citation format, but, I already have papers written in LaTeX that use the old citation keys. This means these files will not work with the new BibTeX file I export from Zotero!
Is there a way to tell Zotero to keep my old citation keys as they are?
NOTE: I found https://github.com/retorquere/zotero-better-bibtex/wiki/Citation-Keys , where you can make the citation keys fixed. However, I do not see how to keep the citation keys as they are in my old BibTeX file.
After making some changes, I exported back from Zotero to BibTeX. Strangely, I noticed that all citation-keys have changed! For example, instead of yoon2008participatory, I have yoon_participatory_2008.
I do not care much about the citation format, but, I already have papers written in LaTeX that use the old citation keys. This means these files will not work with the new BibTeX file I export from Zotero!
Is there a way to tell Zotero to keep my old citation keys as they are?
NOTE: I found https://github.com/retorquere/zotero-better-bibtex/wiki/Citation-Keys , where you can make the citation keys fixed. However, I do not see how to keep the citation keys as they are in my old BibTeX file.
Otherwise, what's happen if you configure the citekey generator and then import your file?
https://github.com/retorquere/zotero-better-bibtex/wiki#got-problems-we-got-fixes
(Be careful and don't forget to backup your Zotero Library.)
No export/import route will preserve all data & you're likely better off manipulating the records in Zotero instead.
But...if you really want to do this despite that advice: The bibtex translator is a file called BibTeX.js in the "translator" directory of your Zotero data folder.
http://www.zotero.org/support/zotero_data
You may edit it to use
var citeKeyFormat = "%a%y%t";
As the OP, I already have LaTeX documents that use the keys in my bib database.
Now I have imported it into zotero, linked zotero to overleaf, and started to edit a LaTeX document on overleaf.
Because zotero altered the keys, my LaTeX document cannot find references.
Thanks for the advice! I've installed it. My next question is, *How can one tell Zotero or the BetterBibTeX (BBT) plugin to preserve the original keys when Zotero imports my bib file.*
> which has configurable and pinnable citekeys.
I tried to configure the "Citation Key Format" item, but I don't know how to tell BBT to preserve the original key. I tried deleting the Citation Key Format, but that wan't allowed.
What's a pinnable key? (I tried googling it but didn't get relevant hits.)
When you import a bib file with BetterBibTeX installed, the citation keys will be added to extra like this automatically.
> When you import a bib file with BetterBibTeX installed, the citation keys will be added to extra like this automatically.
That means
Install BetterBibTeX and import bib files. Then, the original citation keys are preserved!
Thank you!