Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 799 of 806  Not logged in ELOG logo
icon5.gif   Possible to sort attribute chronologically? , posted by Dennis Seitz on Tue Jan 29 04:25:11 2008 
Hi,

We've defined a "LastEdit" attribute for some of our logs so that we can indicate that an entry has been revised, and when that was done. 

From our config:

Attributes =  Last Edit, etc etc
.
.
.
Preset Last Edit =$date
Locked Attributes = Last Edit
Subst on edit Last Edit = $date

This works fine, but when we sort the LastEdit column, the dates are sorted alphabetically. Is there a way to tell Elog to treat this particular attribute 
as a date when sorting?
    icon2.gif   Re: Possible to sort attribute chronologically? , posted by Stefan Ritt on Tue Jan 29 08:02:41 2008 
> Hi,
> 
> We've defined a "LastEdit" attribute for some of our logs so that we can indicate that an entry has been revised, and when that was done. 
> 
> From our config:
> 
> Attributes =  Last Edit, etc etc
> .
> .
> .
> Preset Last Edit =$date
> Locked Attributes = Last Edit
> Subst on edit Last Edit = $date
> 
> This works fine, but when we sort the LastEdit column, the dates are sorted alphabetically. 
> Is there a way to tell Elog to treat this particular attribute as a date when sorting?

You are missing:

Type Last Edit = datetime

which will tread the "Last Edit" attribute as a date/time combination. Actually it's stored 
internally in seconds since Jan 1st 1970, so sorting will work right. The only caveat is that
when you edit an entry, the "Last Edit" is displayed really in seconds since 1970, but I will
fix this in the next release.
    icon2.gif   Re: Possible to sort attribute chronologically? , posted by Stefan Ritt on Tue Jan 29 08:09:50 2008 
> The only caveat is that
> when you edit an entry, the "Last Edit" is displayed really in seconds since 1970, but I will
> fix this in the next release.

I just fixed this in SVN revision #2010. If you would have filled out which operating system you use
with elog, I could tell you how to upgrade.
    icon2.gif   Re: Possible to sort attribute chronologically? , posted by Dennis Seitz on Thu Feb 7 01:33:03 2008 
> > The only caveat is that
> > when you edit an entry, the "Last Edit" is displayed really in seconds since 1970, but I will
> > fix this in the next release.
> 
> I just fixed this in SVN revision #2010. If you would have filled out which operating system you use
> with elog, I could tell you how to upgrade.

Thanks for the help and the bug fix. I have a colleague who keeps our installation up to date, so I'll ask him to install it.
icon5.gif   how to set locale for date/time, posted by svrmarty on Thu Mar 27 14:15:12 2008 

it seems out systemlang is en_US,

#date
Thu Mar 27 14:11:59 CET 2008

and i want to change the local lang only for the elogd.

i tried it with .bash_profile in the elog homedir with

LANG=de_AT
export LANG

but it doesn't work.


how can i change it to get  ?

#date
Don Mär 27 14:09:14 CET 2008

 

thx

    icon2.gif   Re: how to set locale for date/time, posted by Stefan Ritt on Fri Apr 4 08:20:06 2008 

svrmarty wrote:

it seems out systemlang is en_US,

#date
Thu Mar 27 14:11:59 CET 2008

and i want to change the local lang only for the elogd.

i tried it with .bash_profile in the elog homedir with

LANG=de_AT
export LANG

but it doesn't work.


how can i change it to get  ?

#date
Don Mär 27 14:09:14 CET 2008

I investigated this and found that elogd itself does not use the locale properly, so I have to change the code. I will let you know when I fixed this problem.

    icon2.gif   Re: how to set locale for date/time, posted by svrmarty on Sun Apr 6 21:13:27 2008 

Stefan Ritt wrote:

svrmarty wrote:

it seems out systemlang is en_US,

#date
Thu Mar 27 14:11:59 CET 2008

and i want to change the local lang only for the elogd.

i tried it with .bash_profile in the elog homedir with

LANG=de_AT
export LANG

but it doesn't work.


how can i change it to get  ?

#date
Don Mär 27 14:09:14 CET 2008

I investigated this and found that elogd itself does not use the locale properly, so I have to change the code. I will let you know when I fixed this problem.

thx

    icon2.gif   Re: how to set locale for date/time, posted by Stefan Ritt on Wed Apr 9 22:14:05 2008 

svrmarty wrote:

it seems out systemlang is en_US,

#date
Thu Mar 27 14:11:59 CET 2008

and i want to change the local lang only for the elogd.

i tried it with .bash_profile in the elog homedir with

LANG=de_AT
export LANG

but it doesn't work.


how can i change it to get  ?

#date
Don Mär 27 14:09:14 CET 2008

You do not have to change the environment variable, this is all handled inside elogd. I fixed teh above error in SVN revision 2098. Can you try it?

ELOG V3.1.5-3fb85fa6