$JSON_SHOWNAMES

Show fully qualified names in JSON streams as extra attributes of fields and entities.

$JSON_SHOWNAMES { = } 1 | 0

Arguments

  • 1—show the fully-qualified names of each field and entity in the nm attribute
  • 0—identify fields and entities by ID

Defaults

Assignment file: usys.asn or application initialization file
Section: [SETTINGS]
Default value: 0

Description

By default, fields and entities in JSON streams are identified by IDs rather than names. However, for debugging purposes it can be helpful to show the field and entity names, which make it easier to locate where a problem may be occurring.

Output with $JSON_INDENT and $JSON_SHOWNAMES

The following example loads a JSON stream was produced with both $JSON_SHOWNAMES and $JSON_INDENT set to true:

{ 
   "#2" : { 
    "nm" : "JAPAN.JAPAN",
    "type" : "entity",
    "occs" : [ 
     { 
      "id" : "BhJDMTIzNA==",
      "crc" : "00000021",
      "status" : "est",
      "#3" : { 
       "nm" : "ID.JAPAN.JAPAN",
       "value" : "1234"
      },
      "#4" : { 
       "nm" : "BRAND.JAPAN.JAPAN",
       "value" : "SONY"
      },
      "#5" : { 
       "nm" : "DESCRIPTION.JAPAN.JAPAN",
       "value" : "\u3044\u307E"
      }
     }
    ]
   },
   "#6" : { 
    "nm" : "DUM.JAPAN",
    "type" : "entity",
    "occs" : [ 
     { 
      "id" : "VE1QOjQ3ODM0M2RhXzFfYmJmNTAw",
      "crc" : "",
      "status" : "new",
      "#7" : { 
       "nm" : "PB1.DUM.JAPAN",
       "value" : "MickeyMouse"
      },
      "#8" : { 
       "nm" : "PB2.DUM.JAPAN",
       "value" : "DonaldDuck"
      }
     }
    ]
   }
  }

Related Topics