Posted: Wed Oct 30, 2002 12:48 pm Post subject: ESQL code for using XML tag to determine label name
Novice
Joined: 04 Sep 2002 Posts: 18
Thanks for all the replies. May I share how we solved this issue?
A fieldname is identified based on the XML upper level tag. A variable (LABELVAR) is assigned to the fieldname and declared 'found.' The output destination for the labelname is set to the variable (LABELVAR).
-- Set initial variable condition
SET LABELVAR = 'UNKNOWN';
SET BFOUND = FALSE;
-- Determine type of request, assign a corresponding label name, and match found condition
IF FIELDNAME (OutputRoot."XML"."org.hn.pa.ari.Facilities") IS NOT NULL THEN
SET LABELVAR = 'FACILITIES';
SET BFOUND = TRUE;
END IF;
IF NOT BFOUND THEN
IF FIELDNAME (OutputRoot."XML"."org.hn.pa.ari.Finance") IS NOT NULL THEN
SET LABELVAR = 'FINANCE';
SET BFOUND = TRUE;
END IF;
END IF;
-- Set request variable found to the label node name
SET OutputLocalEnvironment.Destination.RouterList.DestinationData[1].labelname = LABELVAR;
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum