Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to spool file with date?

unknown-1052419Feb 4 2014 — edited Feb 5 2014

Hi All,

11.2.0.1

Aix 6

I have a sql script that runs daily and spool its output to a txtfile. I want to attached date to the output txtfile. How do I do that?

For example: prog1.sh

=======

#!/bin/sh

spool output1{date}

select empname from emp where trunc(hiredate)=sysdate-1;

spool off

exit

Thanks,

pK

This post has been answered by Partha Sarathy S on Feb 4 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 5 2014
Added on Feb 4 2014
27 comments
10,361 views