DB2 data from AIX to Windows

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • GreatScott
    New Member
    • Jun 2010
    • 1

    DB2 data from AIX to Windows

    The view GETDATA2 looks like:

    Code:
    SELECT load.didr1, mclocat.*
    FROM cs/unitsinaz, mglg01/mclocat, mglg01/load
    INNER JOIN unitsinaz.ulunit=mclocat.ulunit AND
    mclocat.ulord#=load.diodr# AND mclocat.ulunit=load.diunit
    The batch command looks like:

    Code:
    SBMJOB CMD(EXECUTE VIEW(CS/GETDATA2)
     OUTFILE(CS/MGLG01OUT))  JOB(MGLG01OUT)  JOBD(*USRPRF)                                      
     JOBQ(QS36EVOKE)
    After executing these commands on the AIX and executing a CRTSAVE command, we used FTP to copy the data to a windows machine.

    Trouble is that we cannot read the resulting OUTFILE on the windows machine.
  • kleach
    New Member
    • Jun 2010
    • 15

    #2
    Originally posted by GreatScott
    The view GETDATA2 looks like:

    Code:
    SELECT load.didr1, mclocat.*
    FROM cs/unitsinaz, mglg01/mclocat, mglg01/load
    INNER JOIN unitsinaz.ulunit=mclocat.ulunit AND
    mclocat.ulord#=load.diodr# AND mclocat.ulunit=load.diunit
    The batch command looks like:

    Code:
    SBMJOB CMD(EXECUTE VIEW(CS/GETDATA2)
     OUTFILE(CS/MGLG01OUT))  JOB(MGLG01OUT)  JOBD(*USRPRF)                                      
     JOBQ(QS36EVOKE)
    After executing these commands on the AIX and executing a CRTSAVE command, we used FTP to copy the data to a windows machine.

    Trouble is that we cannot read the resulting OUTFILE on the windows machine.
    To create standard csv for Windows, try

    db2 "export to outfile.csv of del select ...."

    Then ftp the outfile.csv or perhaps give it a better name.

    Comment

    Working...