Results 1 to 10 of 10
  1. #1
    Join Date
    Jan 2009
    Posts
    47

    Unanswered: Can we import data from XML file?

    Hello,

    How can i import data from formated xml file?

    I have a testdb database on sql server 2005.
    My table name is: tblTest with following fields:
    FN,Email,Sub,Tdate,IsDup

    <my:Fields>
    <my:Company>Abc Company</my:Company>
    <my:Contact>
    <my:FN>Aa</my:FN>
    <my:Email>aa@aa.com</my:Email>
    </my:Contact>
    <my:CDetail>
    <my:CSub>hello</my:CSub>
    <my:TDate>01/01/2009</my:TDate>
    <myupStatus>
    <my:IsDup>0</my:IsDup>
    </myupStatus>
    </my:CDetail>
    <my:Contact>
    <my:FN>Bb</my:FN>
    <my:Email>bb@bb.com</my:Email>
    </my:Contact>
    <my:CDetail>
    <my:CSub>testing</my:CSub>
    <my:TDate>01/11/2003</my:TDate>
    <myupStatus>
    <my:IsDup>1</my:IsDup>
    </myupStatus>
    </my:CDetail>
    </my:Fields>

  2. #2
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    it's impossible. it simply can not be done.
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

  3. #3
    Join Date
    Jun 2003
    Location
    Ohio
    Posts
    12,592
    Provided Answers: 1
    For <myupStatus>, you will need to use SQL Server 2008's new Smiley data type.
    If it's not practically useful, then it's practically useless.

    blindman
    www.chess.com: "sqlblindman"
    www.LobsterShot.blogspot.com

  4. #4
    Join Date
    Feb 2004
    Location
    Burbank & Santa Cruz de la Sierra
    Posts
    3,716
    This one time in band camp, we imported XML using a Commodore 64. But then we had to use ODBC to import it to the database, so we just got tired of the conversion process and went out and blew our tubas.
    aka "Paul"
    Non est ei similis.

    I just read "100 Things To Do Before You Die". I was surprised that "Yell for help!!" wasn't one of them

  5. #5
    Join Date
    Jan 2009
    Posts
    47
    We can not load XML data using the XML Bulk load component?

    I wan to import data into a table that already exists in the database.

  6. #6
    Join Date
    Feb 2004
    Location
    Burbank & Santa Cruz de la Sierra
    Posts
    3,716
    Youbetcha you can! I would start by checking out either (a) the XML load topic in Books Online or (b) the XML load topics in various threads on this board using the SEARCH funtionality.

    That done, then if you have any specific questions on your particular implementation, we can most likely help you out (although that duplicate record thread was frankly rather frightening).
    aka "Paul"
    Non est ei similis.

    I just read "100 Things To Do Before You Die". I was surprised that "Yell for help!!" wasn't one of them

  7. #7
    Join Date
    Jan 2009
    Posts
    47
    Quote Originally Posted by TallCowboy0614
    Youbetcha you can! I would start by checking out either (a) the XML load topic in Books Online or (b) the XML load topics in various threads on this board using the SEARCH funtionality.

    That done, then if you have any specific questions on your particular implementation, we can most likely help you out (although that duplicate record thread was frankly rather frightening).

    Thanks, Tallcowboy06114

  8. #8
    Join Date
    Jan 2009
    Posts
    47
    Anybody got the solution?

  9. #9
    Join Date
    Feb 2004
    Location
    Burbank & Santa Cruz de la Sierra
    Posts
    3,716
    I think I provided a solution. Did you have any specific questions about your situation? Have you checked the documentation and previous posts?

    OMG...am I to become mired in this as well? I think not.
    aka "Paul"
    Non est ei similis.

    I just read "100 Things To Do Before You Die". I was surprised that "Yell for help!!" wasn't one of them

  10. #10
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    let me translate.

    Rudba means ~ " Can you tell me exactly what to do in my particular environment for my particular problem because I am too lazy to figure it out myself with the helpful information you have already provided"
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •