I want to change the string datatype to timestamp can anyone help me

0 votes
Aug 21, 2019 in Big Data Hadoop by anonymous
621 views

1 answer to this question.

0 votes

I am not sure if you want the code for Java, Hive or Pig. I am sharing the code for Java:

import java.sql.Timestamp;
import java.text.SimpleDateFormat;
import java.util.Date;

//class and the remaining code

SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss.SSS");
Date parsedDate = dateFormat.parse(yourString);
Timestamp timestamp = new java.sql.Timestamp(parsedDate.getTime());
answered Aug 22, 2019 by Karan

Related Questions In Big Data Hadoop

+1 vote
3 answers

when i tried to run the hdfs namenode -format command...its failed to run..can anyone help me with this???

Hi Suriyaprakash, I guess the path for hadoop ...READ MORE

answered Jul 23, 2018 in Big Data Hadoop by avi_man_utd
12,365 views
0 votes
1 answer

Can anyone help me out to install the following packages R-MR, R-HDFS, and R-HBase on R-HAdoop?

I have understood your problem, I will ...READ MORE

answered May 31, 2019 in Big Data Hadoop by ravikiran
• 4,620 points
660 views
0 votes
1 answer

I need to copy data from one HDFS to another HDFS. Can you help me do so?

I understood your issue. Let me help you ...READ MORE

answered May 16, 2019 in Big Data Hadoop by ravikiran
• 4,620 points
2,501 views
0 votes
1 answer
0 votes
1 answer

while executing this iam getting this error can anyone please help me with the solution please

Hi@srija, It seems you have not provided complete ...READ MORE

answered Apr 6, 2020 in Big Data Hadoop by MD
• 95,460 points
666 views
0 votes
1 answer

How can I use my host machine’s web browser to check my HDFS services running in the VM?

The sole purpose of the virtual machine ...READ MORE

answered Apr 18, 2018 in Big Data Hadoop by Shubham
• 13,490 points
1,462 views
0 votes
3 answers

How to change the delimiter in Sqoop?

--fields-terminated-by <char> READ MORE

answered Jun 25, 2019 in Big Data Hadoop by anonymous
10,623 views
0 votes
2 answers

Hey for all, how to get on large data i want use in hadoop?

Hi, To work with Hadoop you can also ...READ MORE

answered Jul 30, 2019 in Big Data Hadoop by Sunny
1,235 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP