Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2003
    Posts
    7

    Cool Unanswered: import/export help!

    dear sir

    i face problem during importing in db2 udb 8.1.The export is successfull
    but while importing i got the following error

    connect to sample
    export to myfile.ixf of ixf messages msgs.txt select * from staff
    number of rows exported:35

    connect to luse
    import from myfile.ixf of ixf messages msgi.txt insert into staff
    SQL3304N the table does not exists

    and i used GUI tools also....my question is it is necessary to create the
    table prior with the exact structure of the exported table and only datas
    can be imported from the exported file?does db2 does not create the table on its own while importing into a database like sqlserver or oracle.Someone kindly help me and give your valuable guidance.

    thank you
    siva!

  2. #2
    Join Date
    Mar 2003
    Location
    Singapore
    Posts
    200

    Re: import/export help!

    SOrry,sql will not create a table as in oracle and sql server.We need to explicitly create the table.

    That is very clear from the error message " Table dose not exit".

    U can try using the dbmove command for an entire database but for tables u need to use the exp/imp.

    Regards,
    micky

  3. #3
    Join Date
    Mar 2003
    Posts
    7

    Smile thanks micky!

    hi micky

    thanks for your reply.i really feel this forum is very active and usefull.i really appriciate the moderator of this forum and also all other members of this forum.

    wishing you all a great day!
    siva

  4. #4
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: import/export help!

    Siva

    There is an option in IMPORT command to create the table ....

    It is CREATE INTO or CREATE_REPLACE INTO (in place of INSERT INTO) ... I do not remember the correct syntax for these options, so if you have syntax troubles, please refer to the command reference ...

    Cheers

    Sathyaram

    Originally posted by etlsiva
    dear sir

    i face problem during importing in db2 udb 8.1.The export is successfull
    but while importing i got the following error

    connect to sample
    export to myfile.ixf of ixf messages msgs.txt select * from staff
    number of rows exported:35

    connect to luse
    import from myfile.ixf of ixf messages msgi.txt insert into staff
    SQL3304N the table does not exists

    and i used GUI tools also....my question is it is necessary to create the
    table prior with the exact structure of the exported table and only datas
    can be imported from the exported file?does db2 does not create the table on its own while importing into a database like sqlserver or oracle.Someone kindly help me and give your valuable guidance.

    thank you
    siva!

  5. #5
    Join Date
    Mar 2003
    Posts
    7

    Cool thanks sathyaram!

    hi sathyaram

    thanks for your reply.

    import from myfile.ixf of ixf messages msg.txt create into staff

    this worked it creates the table on its own.

    note:dear micky the above command creates table like oracle or sqlserver.so you can give a try.

  6. #6
    Join Date
    Aug 2001
    Location
    UK
    Posts
    4,650

    Re: thanks sathyaram!

    If the table already exists, REPLACE_CREATE will make a difference

    Cheers

    Sathyaram

    Originally posted by etlsiva
    hi sathyaram

    thanks for your reply.

    import from myfile.ixf of ixf messages msg.txt create into staff

    this worked it creates the table on its own.

    note:dear micky the above command creates table like oracle or sqlserver.so you can give a try.

Posting Permissions

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