Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-17810

Incorrect pattern in the macro function examples in Documentation

XMLWordPrintable

    • Icon: Documentation task Documentation task
    • Resolution: Fixed
    • Icon: Trivial Trivial
    • 5.2 (plan)
    • 5.0.0
    • Documentation (D)
    • None

      *Received value*
      MySQL crashed errno 123
      *Macro*
      {{ITEM.VALUE}.regsub("^([A-Z]).*([0-9])", " Problem ID: \1_\2 ")}
      *Output*
      Problem ID: MySQL_123

      However,it will not do as what we have expected.

      *The correct Macro*
      {{ITEM.VALUE}.regsub("^([a-zA-Z])[^0-9]([0-9]+)", " Problem ID: \1_\2 ")}
      {{ITEM.VALUE}.regsub("^([a-Z])[^0-9]([0-9]+)", " Problem ID: \1_\2 ")}
      {{ITEM.VALUE}.regsub("^(\w+)[^0-9]([0-9])", " Problem ID: \1_\2 ")}

       

            mgeneralova Marina Generalova
            yangqing 孙悟空
            Team D
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: