EPrints Technical Mailing List Archive

Message: #08965


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

Re: [EP-tech] Browse by year


Hi Francis,

Your screenshot URL got a bit mangled.  I am not sure how you could have a row in year view that is not clickable.  The date_year field used in the year browsw view in the eprint record is an integer.  If you set it to a value that is not an integer (including just spaces) the year will be set to 0 and appear as 0000 in the browse view.  If you set to an integer greater than 9999, then this year be concatenated to the first four digits (e.g. 12345 becomes just 1234*).  If you set an integer less than 1, then the year will show as 0000 in the browse view.  Finally, if no value is set, the database will store this as null and the link in the browse view should show as "Not Specified".  This is provided by the following line in lib/lang/en/phrases/system.xml:

<epp:phrase id="viewnull_eprint_year">Not Specified</epp:phrase>

Maybe you don't have this phrase but I think it has been present at least since the first release of EPrints 3.4.  Maybe you set this phrase to empty for some reason.  Most likely it was showing "Not Specified" in some place that looked untidy,

Regards

David Newman


*This is technically a bug but unlikely to ever be an issue unless something wei

On 31/05/2022 8:28 am, Francis Jayakanth via Eprints-tech wrote:
CAUTION: This e-mail originated outside the University of Southampton.

Hi,

Values for the date_year column in roughly fifty records in our
repository may not be inserted correctly. As a result, the 'browse by
year' view for such entries is incorrectly created and not clickable.
The following link will take you to a screenshot of the browse view by
year:

https://eur03.safelinks.protection.outlook.com/?url="">
iisc ac in/EQhONAS12hxMseEf7e8lHMUBU0D8IuwQhdbkLrekIGJj1g?e=e1yxHP

As evident from the screenshot, the last item in the third column is
not clickable.

What SQL statement should I use to obtain these records? I've tried
the SQL commands below, but they all return empty sets:

select eprintid, title, official_url from eprint where date_year  like '  %';
select eprintid, title, official_url from eprint where date_year  like ' % '
select eprintid, title, official_url from eprint where date_year  like '  % '

Thanks for your attention.

Best regards, Francis

*** Options: http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech
*** Archive: https://eur03.safelinks.protection.outlook.com/?url="">
*** EPrints community wiki: https://eur03.safelinks.protection.outlook.com/?url="">