[Isis-users] Changes in OD field structure
Eustache Mêgnigbêto
eustache.megnigbeto at outlook.com
Thu Jun 13 14:23:10 CEST 2019
Dear Egbert,
I set the timezone appropriately and it works.
However, I’m still checking how to solve the AM/PM problem. Since the appropriate time date stamp is set in the php.ini.
Many thanks.
From: Egbert De Smet [mailto:egbert.desmet at uantwerpen.be]
Sent: mardi 11 juin 2019 18:10
To: Eustache Mêgnigbêto <eustache.megnigbeto at outlook.com>
Subject: Re: Changes in OD field structure
Continuation :
about the date-format you can consult a webpage like e.g. https://www.php.net/manual/en/function.date.php but you will see it can be complicated.
In ISIS itself you have the date() function (see the Reference Manual for the Formatting Language) which also allows manipulating its formatting by reshuffling substrings of that value returned.
I would have to look into the exact problem however before I can explain more.
However if your only problem is with non-AM/PM time-settings, you can always take 08:00 as morning since the evening in a 24-hours setting will be 20:00 .
Egbert de Smet
Universiteit Antwerpen
________________________________
From: Egbert De Smet
Sent: Tuesday, June 11, 2019 7:02 PM
To: Eustache Mêgnigbêto
Subject: Re: Changes in OD field structure
Eustache,
I suspect that your time-zone in php.ini is not correctly defined.
So locate the correct php.ini (depending of which version of PHP you use, different locations in Windows, XAMPP, LAMP, Linux...) and check for the variable
date.timezone =
You can find the allowed time-zones e.g. for Africa in : https://www.php.net/manual/en/timezones.africa.php
Egbert de Smet
Universiteit Antwerpen
________________________________
From: Eustache Mêgnigbêto <eustache.megnigbeto at outlook.com<mailto:eustache.megnigbeto at outlook.com>>
Sent: Tuesday, June 11, 2019 3:07 PM
To: Egbert De Smet
Subject: RE: Changes in OD field structure
Dear Egbert,
I adopted the option that consists in checking the first two digits of the field.
I have one further question :
The output of the OD field always gives the time of my computer plus one hour, e.g when my computer indicates 07:04:15 for example ABCD will store 08:04:15.
Moreover, ABCD uses the AM and PM format without displaying AM or PM, so when ABCD stores 08:10:23 for example, one could not know if this means 8 Am or PM.
Is there a manner to configure ABCD in order it gives the exact time indicated by my computer with the format 00- 24 (for hours) ?
Many thanks,
From: Egbert De Smet [mailto:egbert.desmet at uantwerpen.be]
Sent: dimanche 9 juin 2019 10:50
To: Eustache Mêgnigbêto <eustache.megnigbeto at outlook.com<mailto:eustache.megnigbeto at outlook.com>>; isis-users at iccisis.org<mailto:isis-users at iccisis.org>
Subject: Re: Changes in OD field structure
Eustache,
indeed for some period there was a bug in the script to store the v980 'operator and date' field where ^o and ^d were switched.
To repair this you could apply, on the records where this is the case, the following proc :
------------------ cut here for proc 'switchv980.prc'
proc(
'd980',
( '<980>', s(replace(replace(replace(v980,'^d','~o'),'^o','^d'),'~o','^o')), '</980>',)
),
(v980/)
------------------ end of proc 'switchv980.prc'
with the command :
mx marc proc=@switchv980.prc<mailto:proc=@switchv980.prc> copy=marc now -all
If you only want to have it correctly displayed (not really changing the records), you can simply use the PFT :
replace(replace(replace(v980,'^d','~o'),'^o','^d'),'~o','^o')
and if you have mixed records, with and without the problem, you can check whether ^o contains '20' at the beginning before applying the replace() :
if (v980^o*0.2='20' then .... fi
The replace command has to be used 3 times (instead of 2) because first you have to set aside the date subfield marked as ~o, then switch the two subfields ^d and ^o, then put the ~o value in ^o. A bit complicated but it works.
Egbert de Smet
Universiteit Antwerpen
________________________________
From: isis-users <isis-users-bounces+egbert.desmet=ua.ac.be at iccisis.org<mailto:isis-users-bounces+egbert.desmet=ua.ac.be at iccisis.org>> on behalf of Eustache Mêgnigbêto <eustache.megnigbeto at outlook.com<mailto:eustache.megnigbeto at outlook.com>>
Sent: Saturday, June 8, 2019 8:09 AM
To: isis-users at iccisis.org<mailto:isis-users at iccisis.org>
Subject: [Isis-users] Changes in OD field structure
Dear all,
I download abcd (version 2.0f, December 2018) to replace the old version I was using.
In one of my databases, I have an operator and date (OD) field. Once I saved the first record with this new version, I noticed that the OD field did not display as expected for the new record. I browsed some existing records and found that the field displays normally. Inspecting the records with the “sin format” internal format, I discovered that the structure is not the same as in the existing records : the subfields (d and o) are permuted so instead of storing the date in ^d and the operator in ^o, the new version stores them in ^o and ^d respectively.
How can I change ?
Thank you in advance.
====================================================================
Eustache Mêgnigbêto
09 BP 477 Saint Michel, Cotonou (République du Bénin)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.iccisis.org/pipermail/isis-users/attachments/20190613/48fb9d6e/attachment.html>
More information about the isis-users
mailing list