This is a discussion on Automating exports of some files within the DB2 forums, part of the Database Server Software category; --> [8.2.1 on LUW, Suse 9] I've got various affiliates that want to be emailed a report on a weekly ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| [8.2.1 on LUW, Suse 9] I've got various affiliates that want to be emailed a report on a weekly basis. Could I write a stored procedure that took two parameters: the affiliate's id, and a filename, and then used EXPORT to create a file with the specified filename, using a query that used the affiliate's id to get the right bookings? I know I could just write a lot of sql and cron it up to dump out a file for each affiliate in turn, but (a) I'm lazy and (b) if we could do it using a stored procedure, then I can probably let my marketing people do it instead of me, so they can add more affiliates as and when they need to. Thoughts? I'm wondering to myself if this is just a case of treating everything like a nail because all I've got is a hammer... |