Reference to webpage without author

Hello everyone,

I will probably answer my own question here, but maybe someone has a better idea how to do this:

I want to reference to a URL (no author, no publishing date or anything else), lets say www.sqlalchemy.org like this:

"As a database interface [SQLAlchemy] was used."
and the corresponding entry should look like:
"SQLAlchemy, www.sqlalchemy.org, Last Accessed on ..."

First, I had the problem that no web page type was available, which was "solved" here: https://forums.zotero.org/discussion/22041/

Now one problem remains: Working with BibTeX, the keys are generated on export, but they use author and publishing year to do so, but both are of course empty. Leading to this fun cite-key: ??????
Since I use the key-format for every other entry in my library, changing the general key-format on export is not possible.

Is there any other way than opening the .bib-file by hand and editing the key EVERYTIME I update my library?

In my opinion the cite-key should be saved alongside the rest of the meta-data inside zotero, like it is done in Mendeley, so one can easily adjust keys that are out of the ordinary. Is there any plan to do this?
  • In my opinion the cite-key should be saved alongside the rest of the meta-data inside zotero, like it is done in Mendeley, so one can easily adjust keys that are out of the ordinary. Is there any plan to do this?
    yes.

    Unfortunately that won't happen very quickly. We'll fix the automatic citekey for items without author.
  • I've had a look - Zotero's default citekey for bibtex would include the first word of the title. It would only produce question marks for unknown years. This means this shouldn't be broken, but produce a citekey like _sqlalchemy_???? which may be ugly but should work. We're always very reluctant to change this as it will break people's existing documents.
  • Thanks for that. Unfortunately, I changed the cite-key-format from being author_firstword_year to authorYear. So I get indeed only question marks. This should work anyway, but if you have more than one webpage for example, you will end up with cite-keys like:
    ????
    ????-I
    ????-II

    So I guess for now, its either switching to another cite-key-format (which will break all MY existing documents), edit the bib-file every time by hand, or switching to another program.

    Maybe the post-editing can be simplified by some scripting. I'll have to look into that.

    Well, thank you anyway!
  • The code generating the cite-key isn't terribly complicated. If you know basic javascript you can likely change it in a custom version of the translator (which I believe you'd have to be using anyway for the modified citekey, right?)
    https://github.com/zotero/translators/blob/master/BibTeX.js#L2126
  • Well, yes I guess I could modify the buildCiteKey-function. Unfortunately I don't speak JavaScript. But I do know python, so probably I could manage.
    If I do come up with something useful, I'll post it on github.
    Thanks.
Sign In or Register to comment.