4 Replies Latest reply on May 11, 2008 7:18 PM by (JohnSpicer)

    XPath Query with /* only returns the first node?

    Level 1
      Hi,<br /><br />I'm using the JDBC Query for Multiple Rows as XML service option to produce the following XML:<br /><br />[5/8/08 14:52:30:674 EDT] 00000043 VariableLogge A com.adobe.idp.dsc.variablelogger.VariableLoggerService log [PID:-1] /process_data/userQueryResult - XML Document:      <br /> <UserList><br />    <User><br />        <firstName type="VARCHAR2">firstname_1</firstName><br />        <lastName type="VARCHAR2">lastname_1</lastName><br />        <userId type="VARCHAR2">userid_1</userId><br />    </User><br />    <User><br />        <firstName type="VARCHAR2">firstname_2</firstName><br />        <lastName type="VARCHAR2">lastname_2</lastName><br />        <userId type="VARCHAR2">userid_2</userId><br />    </User><br />    <User><br />        <firstName type="VARCHAR2">firstname_3</firstName><br />        <lastName type="VARCHAR2">lastname_3</lastName><br />        <userId type="VARCHAR2">userid_3</userId><br />    </User><br />    <User><br />        <firstName type="VARCHAR2">firstname_4</firstName><br />        <lastName type="VARCHAR2">lastname_4</lastName><br />        <userId type="VARCHAR2">userid_4</userId><br />    </User><br /></UserList><br /><br />In a SetValue serivce I have defined the following mapping (xmlFrag is an XML variable):<br /><br />Location  : /process_data/xmlFrag/root<br />Expression: /process_data/userQueryResult/UserList/*<br /><br />However, the mapping only ever returns the first <User> node.<br /><br />[5/8/08 14:52:30:706 EDT] 00000043 VariableLogge A com.adobe.idp.dsc.variablelogger.VariableLoggerService log [PID:-1] /process_data/xmlFrag - XML Document:      <br /> <root><br />    <User><br />        <firstName type="VARCHAR2">firstname_1</firstName><br />        <lastName type="VARCHAR2">lastname_1</lastName><br />        <userId type="VARCHAR2">userid_1</userId><br />    </User><br /></root><br /><br />I have also tried the following mapping expressions, but each produce the same result.<br /><br />Expression: /process_data/userQueryResult/UserList/User<br /><br />Expression: /process_data/userQueryResult/UserList/User[*]<br /><br />I am able to extract a single <User> node with the expression<br /><br />Expression: /process_data/userQueryResult/UserList/User[2]<br /><br />But I am not able to get the complete list of <User> nodes.<br /><br />Any help would be greatly appreciated.<br />Thanks.