Write data to HTML
Posted: Tue Sep 29, 2009 5:25 pm
Is there a way to make DataStage write information out to a HTML table? I have a job currently that writes to a delimited file but I have been asked to convert that to a HTML report of sorts and email it. I believe I may be asked to convert a few more jobs as well so the solution needs to be easy enough to adapt to other jobs.
Things I've been exploring are below
1. Use XML stage and then add the output between <xml> tags using simple cat commands to product a file that the browser can parse. Support for the tag seems limited to IE and works okay but needs a lot of customization for each job.
2. Have the output written to a plain csv/delimited file and then use a shell/awk script to convert that file to html. The job + script can be called in a job sequence and email the result as an attachment from the sequence. This approach seems better as I work through my limited awk knowledge.
Are there any better approaches that have been tried & tested from within DS?
Thanks in advance.
Things I've been exploring are below
1. Use XML stage and then add the output between <xml> tags using simple cat commands to product a file that the browser can parse. Support for the tag seems limited to IE and works okay but needs a lot of customization for each job.
2. Have the output written to a plain csv/delimited file and then use a shell/awk script to convert that file to html. The job + script can be called in a job sequence and email the result as an attachment from the sequence. This approach seems better as I work through my limited awk knowledge.
Are there any better approaches that have been tried & tested from within DS?
Thanks in advance.