Results 1 to 4 of 4
  1. #1
    Join Date
    Nov 2012
    Location
    Zagreb, Croatia
    Posts
    11

    Unanswered: Inserting /loading multiple XML files

    Is there recommended way how to insert/load about 100.000 XML files into tables? Using LOAD utility (how to transfer them correctly to host?), or using some tool like IBM Data Studio-Load option on table, or creating some application that will insert these XMLs or something other?

    Thanks in advance!

  2. #2
    Join Date
    Jan 2012
    Posts
    20
    Are you sure you have to use LOAD? If you use IMPORT you can set the COMMITCOUNT so it doesn't overwhelm your transactional log.

  3. #3
    Join Date
    Sep 2004
    Location
    Belgium
    Posts
    1,126
    There is no IMPORT in DB2 for z/OS. So if your host is a mainframe, it's maybe easiest to write a small program (Java or C) to do the 100000 inserts, with appropriate commits (e.g. once every 100 inserts; this depends on the size of the XML documents).

    In order to use LOAD, you would first have to upload the XML files (e.g. with FTP) to the host, which may cause nasty codepage problems. (Not necessarily, though: if you FTP in binary mode, and make sure the origin is UTF-8, DB2 LOAD can be told to load an UTF-8 file.)
    Anyhow, this complicates matters most of the time since you'll need to allocate storage, decide about dataset structure, etc. So I woud go for the INSERT solution.
    --_Peter Vanroose,
    __IBM Certified Database Administrator, DB2 9 for z/OS
    __IBM Certified Application Developer
    __ABIS Training and Consulting
    __http://www.abis.be/

  4. #4
    Join Date
    Nov 2012
    Location
    Zagreb, Croatia
    Posts
    11
    Thank you for your answer.
    I suppose that INSERT thriugh some application would be better, because we have about 100.000 XMLs that we have to FTP + these XMLs are larger than 32k so we have to put each XML into its own member inside the PDS - as I can see this is pretty painfull to do?

    Have anyone tried to load such huge number of records through Data Studio?
    On IBM Data Studio there's nice option on table -> right click-> Load , where you can choose file, set column and string delimiter and load the file. But I'm not sure it will work fine on 20-30GB or more.

    Thanks, Ivana

Posting Permissions

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