ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » time format issue

Post new topic  Reply to topic
 time format issue « View previous topic :: View next topic » 
Author Message
EAI Developer
PostPosted: Wed Aug 09, 2006 3:44 am    Post subject: time format issue Reply with quote

Centurion

Joined: 30 Nov 2005
Posts: 101
Location: US

Hi All,

I need small help in doing my scenario. I am getting a date format like "08/08/2006 10:48:14 " from DB2 database.I need to convert it like
"2006-08-02T08:03:00-05:00" . I tried using cast function but have no luck in that.I also tried to set the datetimeformat property of message set as i am using a message set in my flow.So can any 1 pls tel me is there any function to convert the date as per my requriment.I can do this using substring and append operations,but i need much gud code.so please help me in this ..I already searched in the forum for this type of issue but i didn't get any useful info.

Thanx,
EAI Developer.
Back to top
View user's profile Send private message Visit poster's website
kimbert
PostPosted: Wed Aug 09, 2006 6:14 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

The options which you mentioned are the only ones I can think of. The best way to get help is to tell us what went wrong with each approach. Make sure you tell us which version and CSD level you are on - it makes a difference.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Aug 09, 2006 12:51 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

If in 6.0 look up the CAST function with the FORMAT addition.

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
EAI Developer
PostPosted: Thu Aug 10, 2006 2:50 am    Post subject: Reply with quote

Centurion

Joined: 30 Nov 2005
Posts: 101
Location: US

Hi,
Thnx for the replies.I working on MB v6.0 with fix pack1 installed.I tried using CAST funtion but the problem i am getting is like this ..

If i give the date format as '01-02-03'(where 01=day,02=month and 03=year) and I mentioned the format option in the CAST function as 'yyyyMMdd' then the result will be '2001-02-03',which is not in real.
got me?If yes ,please help me.


Thnx in advance,
EAI Developer.
Back to top
View user's profile Send private message Visit poster's website
fjb_saper
PostPosted: Thu Aug 10, 2006 3:01 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Use Format string: 'dd-MM-yy' (don't remember if you need capital yy if no century present, look up the cast information on date formats...)
I would have thought this one obvious....
You cast from char to date. Now if you need to display the date in a special format you will have to do the same casting from date to char...

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » time format issue
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.