VISOCO Software  Home | Products | Services | Download | Order | Support | Forum | Resources | Search | About
  RSS feedRSS Feed  FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups  RegisterRegister   ProfileProfile    Log inLog in 
DateTime Display Issue

 
Post new topic   Reply to topic    VISOCO Software Forum Index -> VISOCO dbExpress driver for Sybase ASE
Author Message
MVALVERDE



Joined: 15 Dec 2004
Posts: 4

PostPosted: Sat Jan 22, 2005 12:28 am    Post subject: DateTime Display Issue Reply with quote

I am having trouble with DateTime fields on Sybase ASE 12.x

The table has a DateTime field.

Example Data:

4/2/2001 11:42:00.000 AM
11/9/2000 3:42:00.000 PM

When I load the data into a grid via ClientDataSet in Delphi,
I get the following date displayed

04/02/2001 11:42 11:42:00 AM
11/09/2000 15:42 3:42:00.000 PM


My ShortDateFormat in my app is set to "MM/DD/YYYY HH:MM"

Any idea why the date comes back like such? I am guessing an issue involving going from a 12 hour clock to 24 hour clock format, but I have never encountered this with other DB. I wouldn't pe surprised its another crappy sybase issue Crying or Very sad , but I hope I am just doing something wrong!

Thanks,
Mvalverde
Back to top
View user's profile Send private message
Mat000



Joined: 04 Nov 2003
Posts: 12

PostPosted: Sun Jan 23, 2005 8:03 pm    Post subject: Reply with quote

Just remove the time portion from ShortDateFormat variable. Set it to "MM/DD/YYYY".

You can also use DisplayFormat property of the instance of TSQLTimeStampField to apply the special formatting.

Good luck.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    VISOCO Software Forum Index -> VISOCO dbExpress driver for Sybase ASE All times are GMT + 2 Hours
Page 1 of 1

 


©VISOCO Software. phpBB by phpBB Group