Hi Bhavesh,
I believe that this question is more sqoop related than hive, so I've add sqoop 
user mailing list to CC.

Parameter --hive-drop-import-delims is actually very simple, it will blindly 
remove all '\n', '\r' and '\01' characters from all input data. It will let 
untouched all entires that do not contain such characters. If I understand your 
problem correctly and you're just trying to move your entire MS SQL database to 
hive using sqoop, then you should be fine running the parameter with importing 
all tables at once. Of course on precondition that you can live with loosing 
those three characters. I would suggest using --hive-delims-replacement in case 
that you can't.

And you're welcome, It was pleasure to help you.

Jarcec


On Thu, Feb 09, 2012 at 11:50:50AM +0530, Bhavesh Shah wrote:
> Thanks all for your reply.
> My problem is solved using --hive-drop-import-delims.
> Now I am getting the correct count as that in MS SQL Server.
> But I want to ask one more thing that if I continue to use
> --hive-drop-import-delims option everytime to all tables  (in case of
> sqoop-import-all-tables) while sqoop import, then will it be create some
> problems later or just it will work fine as now? (Means on other tables
> which does not have new line character)
> 
> Thanks Jarek Jarcec Cecho for the solution
> 
> 
> 
> 
> On Thu, Feb 9, 2012 at 11:41 AM, Felix.徐 <ygnhz...@gmail.com> wrote:
> 
> > Hi, I meet the same problem once, then I change the amount of imported
> >  columns it works fine. Sometimes blank rows would be generated by sqoop..I
> > do not actually know what the problem really is.
> 
> 
> 
> 
> 
> 
> 
> >
> > 2012/2/9 Bhavesh Shah <bhavesh25s...@gmail.com>
> >
> >>
> >>
> >>
> >>
> >>    Hello All,
> >>
> >> I have imported near about 10 tables in Hive from MS SQL Server. But when
> >> I try to cross check the records in Hive in one of the Table I have found
> >> more record when I run the query (select count(*) from tblName;).
> >>
> >> Then I have drop the that Table and again imported it in Hive. I have
> >> observed in Console Logs that (Retrieved 203 records). And then I tried
> >> again for (select count(*) from tblName;) and I got the count as 298.
> >>
> >> I dont understand this why this happens. Is anything is wrong in query or
> >> it happens due to some incorrect command of sqoop-import.
> >>
> >> All other table records are fine.
> >>
> >> I got stuck here and I had spend much time to search for this. Pls help
> >> me out from this.
> >>
> >>
> >> --
> >> Thanks and Regards,
> >> Bhavesh Shah
> >>
> >>
> >
> 
> 
> -- 
> Regards,
> Bhavesh Shah

Attachment: signature.asc
Description: Digital signature

Reply via email to