Is this possible ... I want to purge a load of files and have their names in a table.
I have to use SQL because some are selective purges.
Anyway I want I have ...
0129.01 C PRGALL BegSR
0136.00
0138.00 C Eval SQLstm='DELETE FROM ' + FileNM
0144.00 *--------------------------------------------------------------------*
0145.00 * Prepare STMT as initialized in declare section *
0146.00 *--------------------------------------------------------------------*
0147.00 C/EXEC SQL
0147.01 C+ PREPARE S1 FROM :SQLstm
0149.00 C/END-EXEC
But how do I run it ? All examples I see use actual statements and not dynamically built ones i.e.
C/EXEC SQL
C+ DELETE FROM actualFILE
C/END-EXEC
How do I execute my prepared statement?
WP
I have to use SQL because some are selective purges.
Anyway I want I have ...
0129.01 C PRGALL BegSR
0136.00
0138.00 C Eval SQLstm='DELETE FROM ' + FileNM
0144.00 *--------------------------------------------------------------------*
0145.00 * Prepare STMT as initialized in declare section *
0146.00 *--------------------------------------------------------------------*
0147.00 C/EXEC SQL
0147.01 C+ PREPARE S1 FROM :SQLstm
0149.00 C/END-EXEC
But how do I run it ? All examples I see use actual statements and not dynamically built ones i.e.
C/EXEC SQL
C+ DELETE FROM actualFILE
C/END-EXEC
How do I execute my prepared statement?
WP