| Author | 
		  Message
		 | 
		
		  | chanduy9 | 
		  
		    
			  
				 Posted: Thu Jul 20, 2006 6:58 am    Post subject: Converting to TIMESTAMP | 
				     | 
			   
			 
		   | 
		
		
		   Disciple
 
 Joined: 28 Nov 2001 Posts: 177 Location: USA 
  | 
		  
		    
			  
				Hi,
 
 
Is there any way to convert '19991231235959' into timestamp. I tried with cast function but no luck.
 
 
Thanks in Advance,
 
 
Chandra. _________________ Chandra,
 
IBM WebSphere MQ Certified. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | michaelharris | 
		  
		    
			  
				 Posted: Thu Jul 20, 2006 7:01 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Novice
 
 Joined: 09 Jun 2006 Posts: 20
  
  | 
		  
		    
			  
				| CAST('19991231235959' AS TIMESTAMP FORMAT 'yyyyMMddHHmmss') doesn't work? | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | chanduy9 | 
		  
		    
			  
				 Posted: Thu Jul 20, 2006 7:15 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Disciple
 
 Joined: 28 Nov 2001 Posts: 177 Location: USA 
  | 
		  
		    
			  
				Hi,
 
 
I have tried that option...but I am getting the error as shown below:
 
 
2006-07-20 11:16:14.622514     5411   RecoverableException  BIP2521E: (.map_ConstructXML, 12.54) : Error casting a value from CHARACTER to TIMESTAMP. 
 
                                       An error occurred when casting a value of data type CHARACTER to a value of data type TIMESTAMP. 
 
                                       Subsequent messages will indicate the context of the error. 
 
2006-07-20 11:16:14.622521     5411   RecoverableException  BIP2327E: Invalid fields for Gregorian date value: Year '0'; Month '19'; Day '1'. 
 
                                       An attempt was made to interpret the following fields as a valid date in the Gregorian calendar. Year: 0, Month: 19, Day: 1. (January is represented by a month value of 1.) 
 
                                       Correct the message flow definition to ensure that the values being provided as a date value are correct.  This may involve validating that data being read from either a database or a message content is suitable for use as a date. 
 
 
 
Thanks,
 
Chandra. _________________ Chandra,
 
IBM WebSphere MQ Certified. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | chanduy9 | 
		  
		    
			  
				 Posted: Thu Jul 20, 2006 7:25 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Disciple
 
 Joined: 28 Nov 2001 Posts: 177 Location: USA 
  | 
		  
		    
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | kimbert | 
		  
		    
			  
				 Posted: Fri Jul 21, 2006 12:06 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Jedi Council
 
 Joined: 29 Jul 2003 Posts: 5543 Location: Southampton 
  | 
		  
		    
			  
				| Seems to work fine on my machine. Which version and CSD level are you on? | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | chanduy9 | 
		  
		    
			  
				 Posted: Fri Jul 21, 2006 5:40 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Disciple
 
 Joined: 28 Nov 2001 Posts: 177 Location: USA 
  | 
		  
		    
			  
				Hi,
 
I am on version5.0.6. My Broker is running on AIX.
 
 
Thanks,
 
Chandra. _________________ Chandra,
 
IBM WebSphere MQ Certified. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | kimbert | 
		  
		    
			  
				 Posted: Fri Jul 21, 2006 6:47 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Jedi Council
 
 Joined: 29 Jul 2003 Posts: 5543 Location: Southampton 
  | 
		  
		    
			  
				OK - I'm using v6. I recommend you upgrade as soon as possible    
 
Can anyone else make this work on v5 CSD6? | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | madi | 
		  
		    
			  
				 Posted: Fri Jul 21, 2006 6:51 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Chevalier
 
 Joined: 17 Jan 2006 Posts: 475
  
  | 
		  
		    
			  
				you can always break them up into peices and then set your timestamp ..... which is tiresome but atleast it works ........ 5.0 does not handle timestamp formats very well    
 
 
--madi | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | 
		    
		   |