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 » WMB 6.1 and Oracle - TIMESTAMP problem

Post new topic  Reply to topic
 WMB 6.1 and Oracle - TIMESTAMP problem « View previous topic :: View next topic » 
Author Message
santy
PostPosted: Mon Aug 17, 2009 8:56 am    Post subject: WMB 6.1 and Oracle - TIMESTAMP problem Reply with quote

Centurion

Joined: 03 Nov 2006
Posts: 141

Hi,

I have very small code - pasted below - written in my message flow for WMB 6.1 and I'm using Oracle 10g.


PASSTHRU ('INSERT INTO MRA_DBA.TEST_TABLE(ID,CURR_TP) VALUES (?,?)', 2, CURRENT_TIMESTAMP);
call TEST_PROC;

The first PASSTHRU staments inserts the ID as 2 and CURRENT_TIMESTAMP into database.

and the secode CALL statements calls the stored procedure which does the same thing, the stored procedure inserts the ID as 1 and CURRENT_TIMESTAMP.

When I checked the output - I'm getting 1 hr diff.

2 17-AUG-09 17.22.26.000000000
1 17-AUG-09 16.22.26.540485000

Does anybody know where exactly the problem is ?

Thanks
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Aug 17, 2009 9:45 am    Post subject: Re: WMB 6.1 and Oracle - TIMESTAMP problem Reply with quote

Grand High Poobah

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

santy wrote:
Hi,

I have very small code - pasted below - written in my message flow for WMB 6.1 and I'm using Oracle 10g.


PASSTHRU ('INSERT INTO MRA_DBA.TEST_TABLE(ID,CURR_TP) VALUES (?,?)', 2, CURRENT_TIMESTAMP);
call TEST_PROC;

The first PASSTHRU staments inserts the ID as 2 and CURRENT_TIMESTAMP into database.

and the secode CALL statements calls the stored procedure which does the same thing, the stored procedure inserts the ID as 1 and CURRENT_TIMESTAMP.

When I checked the output - I'm getting 1 hr diff.

2 17-AUG-09 17.22.26.000000000
1 17-AUG-09 16.22.26.540485000

Does anybody know where exactly the problem is ?

Thanks

From previous posts on the same subject I believe it to be that a TimeStamp without time zone information is treated differently as the same timestamp with the correct TZ information. You may want to save your timestamps with the TZ information or only save your TimeStamps in UTC...

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
santy
PostPosted: Mon Aug 17, 2009 9:52 am    Post subject: Reply with quote

Centurion

Joined: 03 Nov 2006
Posts: 141

But this happening only in 6.1 and not in 6.0, The same code works correctly over there.
Back to top
View user's profile Send private message
smdavies99
PostPosted: Mon Aug 17, 2009 11:30 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

What you are seeing might be a bug

ON the other hand, it might not.

There could be an issue with 6.0 that has been corrected in 6.1.

If I can, I always store the timestamp as GMT/UTC by taking into consideration the LocalTimeZone offset before writing to the DB. Then I don't have issues when the time changes from BST to GMT and back again.
_________________
WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995

Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions.
Back to top
View user's profile Send private message
MT
PostPosted: Tue Aug 25, 2009 10:30 pm    Post subject: Timestamp issue witn WMB 6.1 and Oracle 10g Reply with quote

Newbie

Joined: 21 Jan 2009
Posts: 3

Hi Santy,

I am facing the same issue when writing a record from WMB 6.1 to Oracle 10g batabase table.

The mesasge flow makes a call to the stored procedure and the timstamp(CURRENT_ TIMESTAMP)is computed by a trigger on the table. The timestamp returned by the trigger is an hour behind the current time.

A manual insert on the database table produces the correct timestamp.

Both the broker and the database servers are running in BST.

Please help if you have solution for this issue?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » WMB 6.1 and Oracle - TIMESTAMP problem
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.