× 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.



Hi,
I got it working, and it is pretty slick. After my first post, I
discovered a few errors. I added the WITH NC to not do commitment control,
added an ALIAS statement & did an EXECUTE IMMEDIATE.
I also shortened the csv file name. This is the working version. I need
to handle errors and set the sequence number, but I was able to change the
FTPMTRINDX member in V64BPCSUSR/FTPSCRIPT.

D PutWrd C CONST('''PUT''')
D Put1 C CONST('''PUT V64BPCSPGM/HTZ MTR')
D Put3 C CONST('.CSV''')
D Udt1 C 'UPDATE FtpMtr SET SRCDTA = '
D Ware C 'WHERE SUBSTR(SRCDTA,1,3) = '
D Cmit C 'WITH NC'

C MOVE DatTim DatTmA
C EVAL PutCmd = Put1 + DatTmA + Put3
C EVAL SqlSmt =
C Udt1 + PutCmd + Ware + PutWrd + Cmit
C******************************
C/EXEC SQL
C+ DROP ALIAS FTPMTR
C/END-EXEC
C******************************
C/EXEC SQL
C+ CREATE ALIAS FTPMTR FOR V64BPCSUSR/FTPSCRIPT(FTPMTRINDX)
C/END-EXEC
C******************************
C/EXEC SQL
C+ EXECUTE IMMEDIATE :SQLSMT
C/END-EXEC

In debug, SQLSMT is
UPDATE FtpMtr SET SRCDTA = 'PUT V64BPCSPGM/HTZ MTR24254.CSV'
WHERE SUBSTR(SRCDTA,1,3) = 'PUT'WITH NC

When I was putting together an e-mail to further explain the problem, I
figured it out. I guess another success story for the 'cardboard
analyst'!

<===================================================>

Terri Harteau
Felker Brothers Corporation
****************
"Do not follow where the path may lead. Go instead where there is no path
and leave a trail."
Ralph Waldo Emerson

****************




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.