I want the output as below format in the output file.
Expected OUTPUT:
Table CUSTOMERMSTR
---------------------------
custno         cjd          custtype
-------------- ----------- ------------
cust123      01-OCT-1900           1 
cust123      08-SEP-1997           1 
cust123      01-JAN-1996           1 
3 rows 
AS of NOW:
Table CUSTOMERMSTR
----------------------------
custno|to_char|custtype
cust123|01-OCT-1900|1
cust123|08-SEP-1997|1
cust123|01-JAN-1996|1
This is my expdata.psql file in the UNIX server. This is not giving the expecting format.
Please help me with what I have to add to get the desired output in my .psql script.
--col custno  format 9999999  heading "custno"              
--col cjd   format A25 heading "cjd"    
--col custtype  format 999999999    heading "custtype"       
\t off
\a
\echo 
\echo Table CUSTOMERMSTR
\echo ----------------------------
\echo
select custno,TO_CHAR(cjd,'DD-MON-YYYY'),custtype   from CUSTOMERMSTR;
