Regular Expressions 101

Save & Share

Flavor

  • PCRE2 (PHP >=7.3)
  • PCRE (PHP <7.3)
  • ECMAScript (JavaScript)
  • Python
  • Golang
  • Java 8
  • .NET 7.0 (C#)
  • Rust
  • Regex Flavor Guide

Function

  • Match
  • Substitution
  • List
  • Unit Tests

Tools

Sponsors
There are currently no sponsors. Become a sponsor today!
An explanation of your regex will be automatically generated as you type.
Detailed match information will be displayed here automatically.
  • All Tokens
  • Common Tokens
  • General Tokens
  • Anchors
  • Meta Sequences
  • Quantifiers
  • Group Constructs
  • Character Classes
  • Flags/Modifiers
  • Substitution
  • A single character of: a, b or c
    [abc]
  • A character except: a, b or c
    [^abc]
  • A character in the range: a-z
    [a-z]
  • A character not in the range: a-z
    [^a-z]
  • A character in the range: a-z or A-Z
    [a-zA-Z]
  • Any single character
    .
  • Alternate - match either a or b
    a|b
  • Any whitespace character
    \s
  • Any non-whitespace character
    \S
  • Any digit
    \d
  • Any non-digit
    \D
  • Any word character
    \w
  • Any non-word character
    \W
  • Non-capturing group
    (?:...)
  • Capturing group
    (...)
  • Zero or one of a
    a?
  • Zero or more of a
    a*
  • One or more of a
    a+
  • Exactly 3 of a
    a{3}
  • 3 or more of a
    a{3,}
  • Between 3 and 6 of a
    a{3,6}
  • Start of string
    ^
  • End of string
    $
  • A word boundary
    \b
  • Non-word boundary
    \B

Regular Expression

/
/
mig

Test String

Code Generator

Generated Code

const regex = /u'([^\\,]+)\\t([^\\]*)\\t([\w]+[\d]+)\\t([^\\]*)\\t((Iub)?[^\\]*IubLink=([^\\]*)|)\\t([^\\']*)/mig; // Alternative syntax using RegExp constructor // const regex = new RegExp('u\'([^\\\\,]+)\\\\t([^\\\\]*)\\\\t([\\w]+[\\d]+)\\\\t([^\\\\]*)\\\\t((Iub)?[^\\\\]*IubLink=([^\\\\]*)|)\\\\t([^\\\\\']*)', 'mig') const str = `[nrun2rtst@scp-1-scripting(HouseStark) ~]\$ ./cliV1.py "cmedit get * UtranCell.(UtranCellId,administrativeState,iubLinkRef,operationalState) -t" WARNING:enmscripting.private.session:On scripting VM, URL and credentials parameters will be ignored [u'SubNetwork,SubNetwork,MeContext,ManagedElement,RncFunction,UtranCell', u'NodeId\\tRncFunctionId\\tUtranCellId\\tadministrativeState\\tiubLinkRef\\toperationalState', u'BTW01R1\\t1\\tWSO6011\\tLOCKED\\t\\t', u'BTW01R1\\t1\\tWSO6012\\tLOCKED\\t\\t', u'CAPEVOR1\\t1\\t6601W21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W31\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W32\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W33\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601W34\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR1\\t1\\t6601X11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601X24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR1\\t1\\t6601Y11\\tUNLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tENABLED', u'CAPEVOR1\\t1\\t6601Y12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR1\\t1\\t6601Y13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR1\\t1\\t6601Y14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR1\\t1\\tCAPTIVE11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR1\\t1\\tCAPTIVE12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR1\\t1\\tCAPTIVE21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR1\\t1\\tCAPTIVE22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR1\\t1\\tCAPWCDMA11\\tUNLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tENABLED', u'CAPEVOR1\\t1\\tCAPWCDMA12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR1\\t1\\tCAPWCDMA13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR1\\t1\\tCAPWCDMA14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR1\\t1\\tLTEG211\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=LTEG2\\tDISABLED', u'CAPEVOR1\\t1\\tLTEG212\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=LTEG2\\tDISABLED', u'CAPEVOR1\\t1\\tLTEG213\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=LTEG2\\tDISABLED', u'CAPEVOR1\\t1\\tMIXED11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=MIXED\\tDISABLED', u'CAPEVOR1\\t1\\tMIXED12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=MIXED\\tDISABLED', u'CAPEVOR1\\t1\\tMIXED13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=MIXED\\tDISABLED', u'CAPEVOR1\\t1\\tMIXED14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=MIXED\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_11_S3C1\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_11\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_11_S3C2\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_11\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_11_S3C3\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_11\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_11_S3C4\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_11\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S2C1\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S2C2\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S2C3\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S3C1\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S3C2\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tNode_B_12_S3C3\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Node_B_12\\tDISABLED', u'CAPEVOR1\\t1\\tSWIPS11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_SWIPS\\tDISABLED', u'CAPEVOR1\\t1\\tW320621\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPEVOR1\\t1\\tW320622\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPEVOR1\\t1\\tW320631\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPEVOR1\\t1\\tW320632\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPEVOR1\\t1\\tW3CAP11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3CAP\\tDISABLED', u'CAPEVOR1\\t1\\tW3CAP12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W3CAP\\tDISABLED', u'CAPEVOR1\\t1\\tW620211\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_W6202\\tDISABLED', u'CAPEVOR1\\t1\\tWSWCAP71\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_WSWCAP\\tDISABLED', u'CAPEVOR1\\t1\\tWU90010\\tUNLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR1,ManagedElement=1,RncFunction=1,IubLink=Iub_WU900\\tENABLED', u'CAPEVOR2\\t1\\t6601W21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W31\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W32\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W33\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601W34\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPEVOR2\\t1\\t6601X11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601X24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPEVOR2\\t1\\t6601Y11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR2\\t1\\t6601Y12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR2\\t1\\t6601Y13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR2\\t1\\t6601Y14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPEVOR2\\t1\\tCAPTIVE11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR2\\t1\\tCAPTIVE12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR2\\t1\\tCAPTIVE21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR2\\t1\\tCAPTIVE22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPEVOR2\\t1\\tCAPWCDMA11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR2\\t1\\tCAPWCDMA12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR2\\t1\\tCAPWCDMA13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR2\\t1\\tCAPWCDMA14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPEVOR2\\t1\\tW3KR611\\tUNLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3KR6\\tDISABLED', u'CAPEVOR2\\t1\\tW3KR612\\tUNLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPEVOR2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3KR6\\tDISABLED', u'CAPW1R2\\t1\\t6601W21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W31\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W32\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W33\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601W34\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601W\\tDISABLED', u'CAPW1R2\\t1\\t6601X11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X23\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601X24\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601X\\tDISABLED', u'CAPW1R2\\t1\\t6601Y11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPW1R2\\t1\\t6601Y12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPW1R2\\t1\\t6601Y13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPW1R2\\t1\\t6601Y14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_6601Y\\tDISABLED', u'CAPW1R2\\t1\\tCAPTIVE11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPW1R2\\t1\\tCAPTIVE12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPW1R2\\t1\\tCAPTIVE21\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPW1R2\\t1\\tCAPTIVE22\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPTIVES\\tDISABLED', u'CAPW1R2\\t1\\tCAPWCDMA11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPW1R2\\t1\\tCAPWCDMA12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPW1R2\\t1\\tCAPWCDMA13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPW1R2\\t1\\tCAPWCDMA14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_CAPWCDMA\\tDISABLED', u'CAPW1R2\\t1\\tLTEG211\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_LTEG2\\tDISABLED', u'CAPW1R2\\t1\\tLTEG212\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_LTEG2\\tDISABLED', u'CAPW1R2\\t1\\tLTEG213\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_LTEG2\\tDISABLED', u'CAPW1R2\\t1\\tLTEG214\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_LTEG2\\tDISABLED', u'CAPW1R2\\t1\\tMIXED11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MIXED\\tDISABLED', u'CAPW1R2\\t1\\tMIXED12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MIXED\\tDISABLED', u'CAPW1R2\\t1\\tMIXED13\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MIXED\\tDISABLED', u'CAPW1R2\\t1\\tMIXED14\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MIXED\\tDISABLED', u'CAPW1R2\\t1\\tMLTTEST11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MLTTEST\\tDISABLED', u'CAPW1R2\\t1\\tMLTTEST12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_MLTTEST\\tDISABLED', u'CAPW1R2\\t1\\tNODEB1111\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_NODEB11\\tDISABLED', u'CAPW1R2\\t1\\tNODEB1112\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_NODEB11\\tDISABLED', u'CAPW1R2\\t1\\tNODEB1113\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_NODEB11\\tDISABLED', u'CAPW1R2\\t1\\tNODEB1114\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_NODEB11\\tDISABLED', u'CAPW1R2\\t1\\tW320621\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPW1R2\\t1\\tW320622\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPW1R2\\t1\\tW320631\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPW1R2\\t1\\tW320632\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3206\\tDISABLED', u'CAPW1R2\\t1\\tW3CAP11\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3CAP\\tDISABLED', u'CAPW1R2\\t1\\tW3CAP12\\tLOCKED\\tSubNetwork=RAN,SubNetwork=RNC,MeContext=CAPW1R2,ManagedElement=1,RncFunction=1,IubLink=Iub_W3CAP\\tDISABLED', u'', u'135 instance(s)'] [nrun2rtst@scp-1-scripting(HouseStark) ~]\$ `; // Reset `lastIndex` if this regex is defined globally // regex.lastIndex = 0; let m; while ((m = regex.exec(str)) !== null) { // This is necessary to avoid infinite loops with zero-width matches if (m.index === regex.lastIndex) { regex.lastIndex++; } // The result can be accessed through the `m`-variable. m.forEach((match, groupIndex) => { console.log(`Found match, group ${groupIndex}: ${match}`); }); }

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 JavaScript, please visit: https://developer.mozilla.org/en/docs/Web/JavaScript/Guide/Regular_Expressions