Thread: xml to sql?

  1. #1
    Registered User
    Join Date
    Nov 2003
    Posts
    183

    xml to sql?

    Hi,

    I have 4 xml files corresponding to 6 tables as a database.
    I want to change them to sql tables, is there any function included in C# libraries to do it automaticaly?

    thanks
    arian

  2. #2
    Jack of many languages Dino's Avatar
    Join Date
    Nov 2007
    Location
    Chappell Hill, Texas
    Posts
    2,332
    A side question - What database are you using? Does it support XML as a native format?
    Mainframe assembler programmer by trade. C coder when I can.

  3. #3
    Registered User
    Join Date
    Nov 2003
    Posts
    183
    Sorry as I dont have enough knowledge about DataBases, I dont know what you mean by "What database are you using?"
    but I geuss the answer to the 2nd question is yes.

    I am going to use the converted database (converted to SQL server) in a C# program.

    here is a part of 2 of xml files:

    Code:
    - <SYNSET_RELATIONS>
    - <SYNSET_RELATION>
      <ID_1>5002303</ID_1> 
      <ID_2>5002341</ID_2> 
      <RELATION_TYPE>Hyponym</RELATION_TYPE> 
      <STATUS>NotChanged</STATUS> 
      </SYNSET_RELATION>
    - <SYNSET_RELATION>
      <ID_1>5001048</ID_1> 
      <ID_2>5001049</ID_2> 
      <RELATION_TYPE>Hyponym</RELATION_TYPE> 
      <STATUS>NotChanged</STATUS> 
      </SYNSET_RELATION>
    - <SYNSET_RELATION>
      <ID_1>5000636</ID_1> 
      <ID_2>5002635</ID_2> 
      <RELATION_TYPE>Hyponym</RELATION_TYPE> 
      <STATUS>NotChanged</STATUS> 
      </SYNSET_RELATION>
    
    -----------------------------------------
    - <Synsets>
    - <SYNSET>
      <ID>5003525</ID> 
      <UID>5100000079</UID> 
      <POS>Noun</POS> 
      <SemanticCategory>Nothing</SemanticCategory> 
      <EXAMPLE>?</EXAMPLE> 
      <GLOSS>علف خوردن حیوانات علف خوار در علف زار و مرتع</GLOSS> 
      <STATUS>Updated</STATUS> 
      <MappedWNsynId /> 
    - <SENSES>
    - <SENSE>
      <WID>5025527</WID> 
      <SID>0</SID> 
      <STATUS>NotChanged</STATUS> 
      </SENSE>
    - <SENSE>
      <WID>5031133</WID> 
      <SID>0</SID> 
      <STATUS>Added</STATUS> 
      </SENSE>
      </SENSES>
      </SYNSET>
    - <SYNSET>
      <ID>5003286</ID> 
      <UID>5100000085</UID> 
      <POS>Noun</POS> 
      <SemanticCategory>Nothing</SemanticCategory> 
      <EXAMPLE>?</EXAMPLE> 
      <GLOSS>حقوق: واگذاشته شدن مالي به مالکي جديد و ازبين رفتن مالکيت مالک قبلي</GLOSS> 
      <STATUS>Edited</STATUS> 
      <MappedWNsynId /> 
    - <SENSES>
    - <SENSE>
      <WID>5030210</WID> 
      <SID>0</SID> 
      <STATUS>NotChanged</STATUS> 
      </SENSE>
    - <SENSE>
      <WID>5030211</WID> 
      <SID>0</SID> 
      <STATUS>NotChanged</STATUS> 
      </SENSE>
      </SENSES>
      </SYNSET>

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. OOP Question DB Access Wrapper Classes
    By digioz in forum C# Programming
    Replies: 2
    Last Post: 09-07-2008, 04:30 PM
  2. Embedded SQL
    By sarac in forum C Programming
    Replies: 1
    Last Post: 05-04-2006, 09:09 AM
  3. XML and data exchange
    By seexml in forum C Programming
    Replies: 0
    Last Post: 04-27-2006, 03:02 PM
  4. Replies: 1
    Last Post: 03-21-2006, 07:52 AM
  5. Problem with embedded SQL in C/C++ (ECPG)
    By NeuralClone in forum C Programming
    Replies: 4
    Last Post: 10-21-2005, 05:16 PM