Posted by bob.speaking on 10/11/07 10:52
>
> Does the file really consist of one single line?
>
> Assuming that you have one record per line in the file, the terminator
> for field 3 should be \r\0\n\0. What happens now is that Field2 in the
> first record extends into the GUID in the second record, and then it
> goes downhill from there.
I'm sorry, cut and pasting sample text file I've removed the correct
syntax :\
In fact the last line has the terminator you specified. :)
> > I've also tried to specify in FMT file SQLUNIQUEID instead of SQLNCHAR
> > and it works perfectly but it imports another data. For example the
> > guid fc0c0c42-438e-4897-96db-8b0489e873ef became
> > 00350031-0039-0033-3100-300030003000
>
> SQLUNIQUEID is what you would use in a binary file. It's not applicable
> here.
I'm migrating this bulk insert frm sql server 2000... in 2005 this
doesn't work. Is it caused by more strictly rules in 2005 engine?
Is sql converting my "char" guid in binary?
Thanks for the prompt reply :)
bob
[Back to original message]
|