Message me off line and I will share what works best for what we need. No pretty enough to post here but gets what I need for info Best Regards Doug
. On Oct 21, 2022, at 19:31, Paul Gilmartin <0000042bfe9c879d-dmarc-requ...@listserv.ua.edu> wrote: On Fri, 21 Oct 2022 16:22:56 -0500, Don Johnson wrote: > Hello! I just tried to post a question with embedded code and fixed > formatting, but it was rejected because HTML is not supported. > I tried a HTTP attachment. LISTSERV ignored it. > Am I reasonably close? (I don't think so...) Bonus points would be given to > convert the date from YYYY.DDD to YYYYMMDD! > With desktop Regina (ANSI Rexx): #! /bin/sh # Test data: echo "\ NONVSAM ------- MYFILE.ABLA.LONGNODE.NODE004.VARNODE1.NOTUSE DATASET-OWNER-----(NULL) CREATION--------2018.341 NONVSAM ------- MYFILE.ABLA.SHORT.NODE4.RPT2.NOTUSE DATASET-OWNER-----(NULL) CREATION--------2015.113 NONVSAM ------- MYFILE.ABLA.MIDDLE.N04.REPT3.NOTUSE DATASET-OWNER-----(NULL) CREATION--------2022.200 NONVSAM ------- MYFILE.ABLA.SHORT.NODE04.RR.NOTUSE DATASET-OWNER-----(NULL) CREATION--------2021.026 " | rexx /dev/fd/3 3<<endrexx signal on novalue do lno = 1 parse pull L if L=='' then leave lno parse var L Opt L.Opt if Opt=='NONVSAM' then iterate lno parse var L.NONVSAM . Q1 '.' Q2 '.' Q3 '.' Q4 '.' Q5 '.' Q6 . parse var L . '--------' yyyy'.' ddd . B = date( 'Base', yyyy'0101', 'Standard' ) + ddd - 1 Std = date( 'Standar', B, 'Base' ) say left( Q4, 8 ) left( Q5, 8 ) Std left( Q3, 8 ) end lno endrexx Prints: NODE004 VARNODE1 20181207 LONGNODE NODE4 RPT2 20150423 SHORT N04 REPT3 20220719 MIDDLE NODE04 RR 20210126 SHORT -- gil ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN