× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On 2/8/2013 3:36 PM, Stone, Joel wrote:
No 3rd party stuff. All internal.

Performing an ETL function, dropping the output files on a network folder.

Need to drop a single sentinel file on another network folder telling a network scheduler that the ETL files are ready to pick up.

I keep a data area showing the ETL start/end dates/times. I would like to send that data area contents as the sentinel file.

I am planning on RTVDTAARA into a CL var, then SQL INSERT that into a table to be dropped onto a network file via QNTC as the sentinel file.

Any better / simpler method?

Your choice seems pretty simple as it is. But for kicks, here's how to
do it in Rexx:

/* Test reading a data area and sending it to a table */

signal on error name command_error
signal on failure name command_error
signal on syntax name syntax_error

'RTVDTAARA BUCK/TRGDTAARA RTNVAR(&dtaara)'
insertStatement = 'insert into buck/sqltest1 (text) values('''dtaara''')'
address EXECSQL
EXECSQL 'set option commit=*none'
EXECSQL insertStatement
say 'SQLSTATE = ' sqlstate

exit

/* ---------------------------------------------------------------- */
command_error:

trace off

parse source system start srcmbr srcfile srclib
say 'Unexpected error at line 'sigl' of REXX program ',
srcmbr' in 'srclib'/'srcfile'. The exception ID is 'rc'.'

exit(right(rc,4))
/* ---------------------------------------------------------------- */
syntax_error:

trace off

parse source system start srcmbr srcfile srclib
say 'Syntax error at line 'sigl' of REXX program ',
srcmbr' in 'srclib'/'srcfile'. The error code is 'rc'.',
' The description is :'
say errortext(rc)

exit(rc)



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.