I have some problems loading a twitter data from a csv, with some multiline records. I have 4 columns id_tweet,text,created_at, username .
When text is enclosed by “ the register is multiline or has comas inside, I show you 3 examples, 1st enclosed by “ with comas inside the text, 2nd enclosed by “ and multiline, 3rd no enclosed by coma no multiline:
793418980342063104,"@realDonaldTrump I am also a $ donor, i can not give much in the way of $ but i do.(poor) My advice is more valuable if you have used it.",2016-11-01T11:46:40.000Z, ReynardGosso
Thanks @realDonaldTrump youâ€™re doing a great Job helping to elect @HillaryClinton !
793418985458929664,This is the 5 year old Nazi German-American @realDonaldTrump that wants 2 be president. No Americans elect adults. https://t.co/IFdQkdDyJN,2016-11-01T11:46:41.000Z, AnthonyNnani
I´m using sqlldr but when I use
infile 'tweetv1.csv' "str '\r\n'"
append continueif last != ','
into table TWEETS
fields terminated by ','
OPTIONALLY ENCLOSED BY '"' AND '"'
( id_TWEET CHAR(4000),
It doesn´t recognize when it’s a new logical record.
Any advice on how to do it?
Thanks a lot,