Tags for timestamp
Error when trying to create a function
Hi, I am trying to create my first function in Teradata SQL Assistant using a script I found on the internet.  the purpose of the function is to convert a timestamp to a unix timestamp and is as follows;   CREATE OR REPLACE FUNCTION oracle_to_unix(in_date IN DATE) RETURN NUMBER  IS BEGIN 
udf timestamp unix timestamp
Convert text to a timestamp
Hi All, I am trying to replicate the below vertica conversion to timestamp to teradata, But I am getting error. Can someone please guide me? Vertica: to_timestamp('June 7, 2016, Hour 0','Month DD, YYYY, Hour HH')  --output: '2016-06-07 00:00:00'          
cast timestamp
How to Import these data into teradata DB using SQL assistant
Hi All,   I have data like these .  Mar 22, 2016 12:06:35 PM
sql teradata timestamp casting importdata
MLOAD will not read in null timestamps
I am using mload to load in a large data set. However, I can't get any of hte data to load because of the error 6760. I know it deals with the timestamp.  
6760 timestamp mload
.Net Provider DateTime-Timestamp Data Type
I need to query a teradata table by referencing a column that is of type Timestamp(6). I'm not successful at getting the right format so far. What do I need to set the Size, Precision, and Scale values to for this to work. (By size, precision, and scale I mean these parameter values in Visual Studio's Dataset Editor)
timestamp datetime .net provider .net teradata
Detect and fix overlapping timestamps by their rank
Hi all, it's my firt post, I hope you can help me here. Within the same day for one ID I have many overlapping events. Basically each event is added on top of scheduled events instead of overwriting existing records. Here is example:    
timestamp overlap
How to convert UTC millisecond to Timestamp(6)
There is a requirement like this: A column from source whose value is UTC millisecond, for example: 1439374041 Then does anyone know, in Teradata, is there any function can convert UTC millisecond to Timestamp (6)? e.g. 1439374041   ->   2015-08-12 10:07:21.000000
timestamp UTC millisecond
Changing time format and adding to date
Hello, I have time in format HH:MM and date in format mm/dd/yyyy. I want COL1 with time formated as HH:MM:SS and COL2 a combination of COL1 and date in format MM/DD/YYYY HH:MM:SS. Also, then I need to subtract COL3 (format mm/dd/yyy hh:mm:ss) from COL2. How can I do this?  
timestamp date format change
Querying the data between 2014 and current date
Hi all, I have some problem about the query which finds the data between 2013-12-31 and today I took invalid timestamp error. The query I used looks like this: select * from table1 where the_date between '2013-12-31' and current_time   Please help me!  
Quer where invalid timestamp
Timestamp TimeZone Cleaner Coding
Hello,  I'm super new to TD and SQL. This code was given to by a co-worker. It works but very slow. Is there a way to speed it up  using 'Interval' and 'Timestamps'? SELECT DISTINCT TimeStamp(FORMAT 'YYYYMMDD') (CHAR(8))  AS CALL_DT, TimeStamp(FORMAT 'HH:MI:SS') (CHAR(8))  AS CALL_TIME, CASE WHEN TEMP1>=240000 
timestamp timezone Cleaner Coding