+3
Under vurdering
Sort per year and month
Hi!
I am trying to sort per date through
&group0=year&sort=month
The issue is that, even when the months in the dates in my zotero data appear as numbers (for example 2024-04), in BibBase appear as the months name, which is fine, but they are sorted in alphabetical order!!!
Is there some way to sort per date?
Thanks!
Kundesupport af UserEcho
Could you send me a link to your page where you use BibBase?
Here. Look for example at 2023: December, February, January, June, March, May, November, October
Thanks. It seems that the Zotero API converts those dates into month names. So unfortunately I think sorting by month won't be possible when using Zotero as your data source.
Hi, just to clarify, this issue isn't specific to Zotero. It also occurs with BibTeX files whenever standard three-letter month abbreviations (e.g., month = {Jan}) or full month names (e.g., month = {January}) are used.
While using numbers (e.g., month = {1}) allows sorting to work, displaying entries as "1 2023" isn't ideal compared to "Jan 2023" or "January 2023".
I noticed a previous request (https://bibbase.userecho.com/communities/1/topics/279-display-month-as-word-even-if-parsed-as-number) to convert numbers into words on display was declined. Because of that, could you please consider adding support for sorting directly when month abbreviations or full month names are provided in the BibTeX file?
Thank you!
When using a bibtex file you can add an additional field that is just used for sorting. For instance, in this example here I've added sort_month and than used &sort=sort_month in my URL to sort by it.
@TechReport{ test5, author = {Test}, title = {In May}, year = 2005, month = {May}, sort_month={5} } @TechReport{ test6, author = {Test6}, title = {In June}, year = 2005, month = {June}, sort_month={6} } @TechReport{ test4, author = {Test}, title = {In April}, year = 2005, month = {April}, sort_month={4} }