#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)VSID_W_MAX_TRAN_DT.+?=(?=\s) (?<VSID_W_MAX_TRAN_DT>[^\s]+)"
Local $sString = "VMID_COUNT =========== 20,588,655" & @CRLF & _
" % Total % Received % Xferd Average Speed Time Time Time Current" & @CRLF & _
" Dload Upload Total Spent Left Speed" & @CRLF & _
"Table.+.+?(?=\.)\W*(opcode_tedc_cs_gmr_id_delta)\W.+?(?=,+)\,\s+numRows\=+(?<LogTime>[^\,]+)" & @CRLF & _
"" & @CRLF & _
"Loading data to table gmr.opcode_tedc_cs_gmr_id_delta" & @CRLF & _
"Table gmr.opcode_tedc_cs_gmr_id_delta stats: [numFiles=5, numRows=8986691, totalSize=937732401, rawDataSize=928745710]" & @CRLF & _
"" & @CRLF & _
" 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0" & @CRLF & _
"100 997 100 997 0 0 114k 0 --:--:-- --:--:-- --:--:-- 162k" & @CRLF & _
"" & @CRLF & _
" 0 0 0 397 0 0 1650 0 --:--:-- --:--:-- --:--:-- 1650" & @CRLF & _
"VSID_W_MAX_TRAN_DT ========== 9,070,691" & @CRLF & _
" % Total % Received % Xferd Average Speed Time Time Time Current" & @CRLF & _
" Dload Upload Total Spent Left Speed" & @CRLF & _
"" & @CRLF & _
" 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0" & @CRLF & _
"100 997 100 997 0 0 108k 0 --:--:-- --:--:-- --:--:-- 139k" & @CRLF & _
"" & @CRLF & _
" 0 0 0 403 0 0 944 0 --:--:-- --:--:-- --:--:-- 944" & @CRLF & _
"NON_PSP_VSID_COUNT =========== 39,869,169" & @CRLF & _
" % Total % Received % Xferd Average Speed Time Time Time Current" & @CRLF & _
" Dload Upload Total Spent Left Speed" & @CRLF & _
"" & @CRLF & _
" 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0" & @CRLF & _
"100 997 100 997 0 0 112k 0 --:--:-- --:--:-- --:--:-- 162k" & @CRLF & _
"" & @CRLF & _
" 0 0 0 398 0 0 7223 0 --:--:-- --:--:-- --:--:-- 7223" & @CRLF & _
"PSP_VSID_COUNT =========== 45,083" & @CRLF & _
"sendmail: warning: inet_protocols: disabling IPv6 name/address support: Address family not supported by protocol" & @CRLF & _
"postdrop: warning: inet_protocols: disabling IPv6 name/address support: Address family not supported by protocol" & @CRLF & _
"[send_coll_stats.sh:] Sent e-mail with collection stats" & @CRLF & _
"/jobs/prod/proclib/CMLS_HADOOP_proc_v02.ksh: line 75: print: command not found" & @CRLF & _
"/jobs/prod/proclib/CMLS_trailer.ksh: line 9: print: command not found"
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYGLOBALFULLMATCH)
Local $aFullArray[0]
For $i = 0 To UBound($aArray) -1
_ArrayConcatenate($aFullArray, $aArray[$i])
Next
$aArray = $aFullArray
; Present the entire match result
_ArrayDisplay($aArray, "Result")
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm