A Store "not nice" answer to timeStampString

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

A Store "not nice" answer to timeStampString

Dennis smith-4
I see why, but the timeStampString returned is of the form
        10-04-01 1:45:33 AM
I see it uses the Locale, but that means ...
  1. its different from user to user
  2. its ambiguous if you want to parse it
Would it not be better if it was
   yyyy-mm-dd
???


-- 
Dennis Smith                 		         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1 416.798.0948
509-2001 Sheppard Avenue East        [hidden email]
Toronto, ON M2J 4Z8              [hidden email]
Canada			         http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the DVP

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: A Store "not nice" answer to timeStampString

Alan Knight-2
Why not just ask for the timestamp instead?

At 10:47 AM 2010-04-01, Dennis Smith wrote:
I see why, but the timeStampString returned is of the form
        10-04-01 1:45:33 AM
I see it uses the Locale, but that means ...
  1. its different from user to user
  2. its ambiguous if you want to parse it
Would it not be better if it was
   yyyy-mm-dd
???



-- 
Dennis
Smith                
   
        
         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1
416.798.0948
509-2001 Sheppard Avenue East       
[hidden email]
Toronto, ON M2J
4Z8             
[hidden email]
Canada  
        
        
        

http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the
DVP
_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

--
Alan Knight [|], Engineering Manager, Cincom Smalltalk

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: A Store "not nice" answer to timeStampString

Kooyman, Les
In reply to this post by Dennis smith-4
Dennis:
 
Indeed this is one of the problems when reading and interpreting timestamps: if the source of the data is not within your control, it has a good chance of being, as far as you are concerned, arbitrary.
 
I've been thinking for a while now that with the proliferation of formats related to increased locale support, we might benefit from supporting a culturally-independent timestamp format, especially for certain internal uses (but also for any data interchange uses customers might have that transcend cultural boundaries). I've been thinking it should be based on ISO-8601 ( http://en.wikipedia.org/wiki/ISO_8601 ), which is also the basis for the CLDR timestamp formats.
 
In the interim I suggest folks use timestamps created by the C locale as a substitute.
 
Then again, if your data is of "arbitrary" external origin, you may have to take application-specific measures to handle the incoming text.
 
Les Kooyman
Cincom


From: [hidden email] on behalf of Dennis Smith
Sent: Thu 4/1/2010 9:47 AM
To: VWNC,
Subject: [vwnc] A Store "not nice" answer to timeStampString

I see why, but the timeStampString returned is of the form
        10-04-01 1:45:33 AM
I see it uses the Locale, but that means ...
  1. its different from user to user
  2. its ambiguous if you want to parse it
Would it not be better if it was
   yyyy-mm-dd
???


-- 
Dennis Smith                 		         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1 416.798.0948
509-2001 Sheppard Avenue East        [hidden email]
Toronto, ON M2J 4Z8              [hidden email]
Canada			         http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the DVP

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: A Store "not nice" answer to timeStampString

Kooyman, Les
In reply to this post by Alan Knight-2
Also a good approach.


From: [hidden email] on behalf of Alan Knight
Sent: Thu 4/1/2010 10:00 AM
To: Dennis Smith; VWNC,
Subject: Re: [vwnc] A Store "not nice" answer to timeStampString

Why not just ask for the timestamp instead?

At 10:47 AM 2010-04-01, Dennis Smith wrote:
I see why, but the timeStampString returned is of the form
        10-04-01 1:45:33 AM
I see it uses the Locale, but that means ...
  1. its different from user to user
  2. its ambiguous if you want to parse it
Would it not be better if it was
   yyyy-mm-dd
???



-- 
Dennis
Smith                
   
        
         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1
416.798.0948
509-2001 Sheppard Avenue East       
[hidden email]
Toronto, ON M2J
4Z8             
[hidden email]
Canada  
        
        
        

http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the
DVP
_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

--
Alan Knight [|], Engineering Manager, Cincom Smalltalk

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc
Reply | Threaded
Open this post in threaded view
|

Re: A Store "not nice" answer to timeStampString

Dennis smith-4
In reply to this post by Alan Knight-2
I do -- NOW -- but the other had seemed simpler at the time.

It can also be confusing if one DISPLAY's the timeStampString since the
format is pretty ambiguous having only a 2 digit year.

That aside it WAS my fault -- but thought it worthwhile to point out

On 01/04/2010 11:00 AM, Alan Knight wrote:
Why not just ask for the timestamp instead?

At 10:47 AM 2010-04-01, Dennis Smith wrote:
I see why, but the timeStampString returned is of the form
        10-04-01 1:45:33 AM
I see it uses the Locale, but that means ...
  1. its different from user to user
  2. its ambiguous if you want to parse it
Would it not be better if it was
   yyyy-mm-dd
???



-- 
Dennis
Smith                
   
        
         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1
416.798.0948
509-2001 Sheppard Avenue East       
[hidden email]
Toronto, ON M2J
4Z8             
[hidden email]
Canada  
        
        
        

http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the
DVP
_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc

--
Alan Knight [|], Engineering Manager, Cincom Smalltalk

-- 
Dennis Smith                 		         +1 416.798.7948
Cherniak Software Development Corporation   Fax: +1 416.798.0948
509-2001 Sheppard Avenue East        [hidden email]
Toronto, ON M2J 4Z8              [hidden email]
Canada			         http://www.CherniakSoftware.com
Entrance off Yorkland Blvd south of Sheppard Ave east of the DVP

_______________________________________________
vwnc mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/vwnc