SQL Server Developer Center > SQL Server Forums > SQL Server XML > SQLState = S1000, NativeError = 0 Error = [Microsoft][SQL Native Client]Unable to open BCP host data-file
Ask a questionAsk a question
 

QuestionSQLState = S1000, NativeError = 0 Error = [Microsoft][SQL Native Client]Unable to open BCP host data-file

  • Tuesday, April 28, 2009 4:15 PMMike Kacos Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I am trying to BCP an xml file into a SQLExpress database.  I am getting the following error:
    SQLState = S1000, NativeError = 0 Error = [Microsoft][SQL Native Client]Unable to open BCP host data-file

    The command line below is EXACTLY what I am trying to run. 
    C:\EDI\mine>bcp itcedi.dbo.bol_view in  -ic:\edi\mine\inbound.xml -Slocalhost\SQLEXPRESS -T -fc:\edi\mine\bolview.xsd

    I have checked my rights to the folder and I have complete rights.
    I have tried to use quotes to no avail.

    I need some help, please.




All Replies

  • Wednesday, April 29, 2009 7:00 AMchinthapalli Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Hello,


    Check whether the file exists in the input location you have given.

    if the file exixts. try this.

    C:\EDI\mine>bcp itcedi.dbo.bol_view in  "c:\edi\mine\inbound.xml" -T -c -S servername1


    Thanks,
    Shanthi
  • Tuesday, November 03, 2009 10:46 AMAnuj Sadani Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    also try to use -x as you are dealing with xml files.