instead of org.apache.hcatalog.pig.HCatStorer() use org.apache.hive.hcatalog.pig.HCatStorer()
On Mon, Jun 2, 2014 at 12:54 PM, Rahul Channe <drah...@googlemail.com> wrote: > Try loading the data in a temporary hive table with datatype as String, > then you can populate the data in the final table > > insert into table timestamp_example select > from_unixtime(unix_timestamp(v_time ,'MM/dd/yyyy HH:mm') ) from > timestamp_example_temp; > > > On Mon, Jun 2, 2014 at 3:23 PM, Patcharee Thongtra < > patcharee.thong...@uni.no> wrote: > >> Hi, >> >> I am using hive 0.13 and I created a table with a column date in >> timestamp format. >> When I used pig script to store data into the table I got exception >> java.lang.TypeNotPresentException: Type timestamp not present >> >> This is my pig script >> >> result = FOREACH result_raw GENERATE generate ToDate(dateString, >> 'yyyy-MM-dd HH:mm:ss') as date:DateTime, zone, z, u, v, th, qv, ph; >> store result into 'fino31' using org.apache.hcatalog.pig.HCatStorer(); >> >> This link https://cwiki.apache.org/confluence/display/Hive/ >> HCatalog+LoadStore#HCatalogLoadStore-DataTypesSupportedinHive0.13. >> 0andLaterReleases.1 mentions that hive 0.13 supports timestamp and in >> pig we should provide DateTime to store in timestamp column. I did as >> mentioned but I got the exception. >> >> Any suggestion is appreciated. >> >> Patcharee >> >> >> >> > -- Thanks, Eugene -- CONFIDENTIALITY NOTICE NOTICE: This message is intended for the use of the individual or entity to which it is addressed and may contain information that is confidential, privileged and exempt from disclosure under applicable law. If the reader of this message is not the intended recipient, you are hereby notified that any printing, copying, dissemination, distribution, disclosure or forwarding of this communication is strictly prohibited. If you have received this communication in error, please contact the sender immediately and delete it from your system. Thank You.