When table is created it is the time stamp when the table was created. When any DDL is done it is the last DDL time it looks
0: jdbc:hive2://rhes564:10010/default> create table test (col1 int, col2 string); No rows affected (0.168 seconds) 0: jdbc:hive2://rhes564:10010/default> show create table test; +-------------------------------------------------------------------+--+ | createtab_stmt | +-------------------------------------------------------------------+--+ | CREATE TABLE `test`( | | `col1` int, | | `col2` string) | | ROW FORMAT SERDE | | 'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' | | STORED AS INPUTFORMAT | | 'org.apache.hadoop.mapred.TextInputFormat' | | OUTPUTFORMAT | | 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat' | | LOCATION | | 'hdfs://rhes564:9000/user/hive/warehouse/oraclehadoop.db/test' | | TBLPROPERTIES ( | | 'transient_lastDdlTime'='1452120468') | +-------------------------------------------------------------------+--+ 13 rows selected (0.06 seconds) 0: jdbc:hive2://rhes564:10010/default> insert into test values(1,'a'); INFO : Table oraclehadoop.test stats: [numFiles=1, numRows=1, totalSize=4, rawDataSize=3] No rows affected (1.517 seconds) 0: jdbc:hive2://rhes564:10010/default> show create table test; +-------------------------------------------------------------------+--+ | createtab_stmt | +-------------------------------------------------------------------+--+ | CREATE TABLE `test`( | | `col1` int, | | `col2` string) | | ROW FORMAT SERDE | | 'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' | | STORED AS INPUTFORMAT | | 'org.apache.hadoop.mapred.TextInputFormat' | | OUTPUTFORMAT | | 'org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat' | | LOCATION | | 'hdfs://rhes564:9000/user/hive/warehouse/oraclehadoop.db/test' | | TBLPROPERTIES ( | | 'COLUMN_STATS_ACCURATE'='true', | | 'numFiles'='1', | | 'numRows'='1', | | 'rawDataSize'='3', | | 'totalSize'='4', | | 'transient_lastDdlTime'='1452120510') | +-------------------------------------------------------------------+--+ 0: jdbc:hive2://rhes564:10010/default> select cast(from_unixtime(1452120468) AS timestamp); +------------------------+--+ | _c0 | +------------------------+--+ | 2016-01-06 22:47:48.0 | +------------------------+--+ 0: jdbc:hive2://rhes564:10010/default> select cast(from_unixtime(1452120510) AS timestamp); +------------------------+--+ | _c0 | +------------------------+--+ | 2016-01-06 22:48:30.0 | +------------------------+--+ Dr Mich Talebzadeh LinkedIn <https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw> https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw Sybase ASE 15 Gold Medal Award 2008 A Winning Strategy: Running the most Critical Financial Data on ASE 15 <http://login.sybase.com/files/Product_Overviews/ASE-Winning-Strategy-091908.pdf> http://login.sybase.com/files/Product_Overviews/ASE-Winning-Strategy-091908.pdf Author of the books "A Practitioner’s Guide to Upgrading to Sybase ASE 15", ISBN 978-0-9563693-0-7. co-author "Sybase Transact SQL Guidelines Best Practices", ISBN 978-0-9759693-0-4 Publications due shortly: Complex Event Processing in Heterogeneous Environments, ISBN: 978-0-9563693-3-8 Oracle and Sybase, Concepts and Contrasts, ISBN: 978-0-9563693-1-4, volume one out shortly <http://talebzadehmich.wordpress.com/> http://talebzadehmich.wordpress.com NOTE: The information in this email is proprietary and confidential. This message is for the designated recipient only, if you are not the intended recipient, you should destroy it immediately. Any information in this message shall not be understood as given or endorsed by Peridale Technology Ltd, its subsidiaries or their employees, unless expressly so stated. It is the responsibility of the recipient to ensure that this email is virus free, therefore neither Peridale Ltd, its subsidiaries nor their employees accept any responsibility. From: Ophir Etzion [mailto:op...@foursquare.com] Sent: 06 January 2016 22:15 To: user@hive.apache.org Subject: last_modified_time and transient_lastDdlTime - what is transient_lastDdlTime for. I want to know for each of my tables the last time it was modified. some of my tables don't have last_modified_time in the table parameters but all have transient_lastDdlTime. transient_lastDdlTime seems to be the same as last_modified_time in some of the tables I randomly cheked. what is the time in transient_lastDdlTime? if it also the modified time why is there also last_modified_time? Thanks, Ophir