|
Hi list:
I am using the EXCSQLSTM command to execute SQL stuff within CL's. I am developing one today, as follows.
EXCSQLSTM SQLSTM('INSERT INTO WHCON/DUPITMWRK + (SELECT + ''TIM'' AS LOC, + ''MG'' AS ENV, + CASE + WHEN SUBSTR(ITNBR,1,1) = ''T'' THEN ITNBR + WHEN SUBSTR(ITNBR,1,1) <> ''T'' AND SUBSTR(ITNBR,15,1) = '' '' + THEN ''T''||SUBSTR(ITNBR,1,14) +
WHEN SUBSTR(ITNBR,15,1) <> '' '' THEN ITNBR + END AS ITEM + FROM ITMRVA WHERE SUBSTR(STID,1,1) = ''T'' + GROUP BY ITNBR ORDER BY ITNBR)')
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.