DBAsupport.com Forums - Powered by vBulletin
Results 1 to 2 of 2

Thread: downloading data into flat file ?

  1. #1
    Join Date
    Nov 2001
    Posts
    27
    Hello

    Could anyone please let me know how to "unload" a table into a flat file ?

    I want to take all the data from a table and put it into a file.

    I have created a 'master.sql' file with the followin lines of code:

    set feedback off
    set heading off spool slave.sql select 'select * from |'THISTABLE'|';
    spool off

    When I run 'master.sql' I am getting these errors.

    ./master.sql: spool: command not found

    Thank you.

  2. #2
    Join Date
    Oct 2000
    Location
    Germany
    Posts
    1,185
    Try some reformatting:

    set feedback off
    set heading off
    spool slave.sql

    select 'select * from thistable'
    from table_name;

    spool off

    You are spooling select statements to slave.sql. Your current sql*plus statement won't work without a from clause.

    Good luck.
    David Knight
    OCP DBA 8i, 9i, 10g

Posting Permissions

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


Click Here to Expand Forum to Full Width