Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 alexC
		
			alexC
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi,
I am loading a timestamp field in the format '2021-08-02 11:00:00+00' and I cannot convert it to DAY or MONTH since it is probably not recognized as timestamp.
In the load script I have this format: SET TimestampFormat='YYYY-MM-DD hh:mm:ss[.fff] TT';
What can I do?
 Digvijay_Singh
		
			Digvijay_Singh
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try something like this -
Timestamp#(subfield('2021-08-02 11:00:00+00','+',1),'YYYY-MM-DD hh:mm:ss')
//You may need to use the actual field instead of the subfield I have used in the example.
'+00' indicates time zone I think, but not sure how do you want to utilize it, there is a function in qlik to convert time to local timing but I never used that -
 alexC
		
			alexC
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thank you, actually it worked, but it is a temporary solution till I understand how to use it.
I think '+00' represents the summer/winter time adjustment and/or time zone.
By trimming (ignoring) it my data will deviate by 2-3 hours (in my particular case).
 
					
				
		
 vinieme12
		
			vinieme12
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		as below
temp:
load 
new_timestamp
,Day(new_timestamp) as day
,date(floor(new_timestamp)) as date
;
load timestamp#(replace(timstaaamp,' ','T'),'YYYY-MM-DDhh:mm±hh:mm')  as new_timestamp inline [
timstaaamp
2021-08-02 11:00:00+01:00
];
