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

Thread: Export To Fixed Length File

  1. #1
    Join Date
    Jul 2002
    Posts
    1

    Question

    I need to create a file from a query of an oracle table.
    The output file needs to be structured in positions. Example,
    from position 1 to 5 there must contain only those values, from 6 to 15 another field, 16 to 21 another field etc. This would be a 90 byte file. So there would be 90 characters for each line. After building the file, I need to send it to an emal address. Is there a way to do this? Please give me an example.

    Thanks!

  2. #2
    Join Date
    Apr 2001
    Location
    Czechia
    Posts
    712
    Fixed-length fields you can get in SQL*Plus by setting field formats and field separator or with SQL (PL/SQL) by using LPAD and RPAD functions and concatenating fields to one string.

    Sending the email is another issue, depends on way you'd like to use and on your OS.
    Ales
    The whole difference between a little boy and an adult man is the price of toys

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