Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
How can I write "[A-Z] * " in Qlikview?
thank you
Stefan Wühl
Function RegExFind(iString, Pattern, Separator, IgnoreCase)
for i = 0 To Found.Count - 1
Result = Result & Found(i).Value & Separator
next
RegExFind = left(Result, len(Result)-1)
End Function
Hello Stefan,
I have used this thread as reference several times. Not sure if anything changed, but I noticed copying the RegExFind() function verbatim, it was shaving off the last character on searches. does that '-1' belong at the end where it puts the result in the function variable? Maybe something changed on their ordinal system, but I've seen this thread for regex referenced in many other threads, and would hate for the next person to come along and have their regex experience be compromised.
Also, question for you. I've been trying to find out how to reference the character classes. .NET documentation seems to indicate character classes are possible (i.e. \p{IsCyrillic}). However, I'm not finding those same character classes working in the VBscript. Do you know how to invoke the character classes in the VB script regex?
Really appreciate this thread btw, Thank you! ~E
In my case its working, here i attached my script:
WHERE
RegTelecom('$(vCalledNumber)', CalledNumberPattern ,0) AND
RegTelecom('$(vCallingNumber)', CallingNumberPattern ,0) AND
RegTelecom('$(vorigIpv4v6Addr)',origIpv4v6AddrPattern,0) AND
RegTelecom('$(vdestIpv4v6Addr)',destIpv4v6AddrPattern,0)
;
Function RegTelecom(iString, Pattern, IgnoreCase)
set RE = New RegExp
RE.Pattern = Pattern
RE.IgnoreCase = IgnoreCase
RegTelecom = RE.Test(iString)
End Function