Subject: [Netconf] a question about subtree filter

From: "Fengchong (frank)" <[email-masked]>
Date: Tue, 21 Mar 2017 12:04:21 +0000

Hi all,

   I have a question about subtree filter mechanism.

If NETCONF server has these data listed below:

         <top xmlns="http://example.com/schema/1.2/config">
           <users>
            <user>
               <name>root</name>
               <company-info>
                 <dept>1</dept>
                 <id>1</id>
               </company-info>
             </user>
             <user>
               <name>fred</name>
               <company-info>
                 <id>2</id>
               </company-info>
             </user>
           </users>
         </top>

  Then ,the filter is :

        <filter type="subtree">

           <top xmlns="http://example.com/schema/1.2/config">

             <users>

               <user>

                 <name/>

                 <company-info>

                   <id>1</id>

                 </company-info>

               </user>

             </users>

           </top>

         </filter>

And ,the result is:
a)
   <top xmlns="http://example.com/schema/1.2/config">
           <users>
            <user>
               <name>root</name>
               <company-info>
                 <dept>1</dept>
                 <id>1</id>
               </company-info>
             </user>
           </users>
         </top>

Or
b)
   <top xmlns="http://example.com/schema/1.2/config">
           <users>
            <user>
               <name>root</name>
               <company-info>
                 <dept>1</dept>
                 <id>1</id>
               </company-info>
             </user>
             <user>
               <name>fred</name>
             </user>
           </users>
         </top>

________________________________
冯冲
华为技术有限公司 Huawei Technologies Co., Ltd.
[Company_logo]

Phone:
Fax:
Mobile: 18519117316
Email: [email-masked]
地址：南京市软件大道101号华为南京基地 邮编：210001
Huawei Technologies Co., Ltd.

http://www.huawei.com
________________________________
本邮件及其附件含有华为公司的保密信息，仅限于发送给上面地址中列出的个人或群组。禁
止任何其他人以任何形式使用（包括但不限于全部或部分地泄露、复制、或散发）本邮件中
的信息。如果您错收了本邮件，请您立即电话或邮件通知发件人并删除本邮件！
This e-mail and its attachments contain confidential information from HUAWEI, which
is intended only for the person or entity whose address is listed above. Any use of the
information contained herein in any way (including, but not limited to, total or partial
disclosure, reproduction, or dissemination) by persons other than the intended
recipient(s) is prohibited. If you receive this e-mail in error, please notify the sender by
phone or email immediately and delete it!

---

From: "Guopeipei (Peipei Guo)" <[email-masked]>
Date: Fri, 31 Mar 2017 11:48:52 +0000

Hi Fengchong,

I think the result is ‘a’.

发件人: Netconf [mailto:[email-masked]] 代表 Fengchong (frank)
发送时间: 2017年3月21日 20:04
收件人: [email-masked]
主题: [Netconf] a question about subtree filter

Hi all,

  Then ,the filter is :

        <filter type="subtree">

             <users>

               <user>

                 <name/>

                 <company-info>

                   <id>1</id>

                 </company-info>

               </user>

             </users>

           </top>

         </filter>

And ,the result is:
a)

Or
b)

Phone:
Fax:
Mobile: 18519117316
Email: [email-masked]<mailto:[email-masked]>
地址：南京市软件大道101号华为南京基地 邮编：210001
Huawei Technologies Co., Ltd.

http://www.huawei.com