How to extract a distinct value in simple xml in php
<pre><code>SimpleXMLElement Object (
[@attributes] =&gt; Array ( 
    [type] =&gt; array 
)
[time-entry] =&gt; Array (
    [0] SimpleXMLElement Object (
        [date] =&gt; 2010-06-17 
        [description] =&gt; "MGIN0:internal administration"
        [hours] =&gt; 7.5
        [id] =&gt; 26334957 
        [person-id] =&gt; 4912655 
        [project-id] =&gt; 4437844
        [todo-item-id] =&gt; SimpleXMLElement Object ( 
            [@attributes] =&gt; Array (
                [type] =&gt; integer 
                [nil] =&gt; true 
            ) 
        ) 
    ) 
    [5] =&gt; SimpleXMLElement Object (
        [date] =&gt; 2010-06-18 
        [description] =&gt; "MGPJ1:WG'07 Outreach, schedule send"
        [hours] =&gt; 0.25 
        [id] =&gt; 26376694
        [person-id] =&gt; 2962280 
        [project-id] =&gt; 3652412 
        [todo-item-id] =&gt; SimpleXMLElement Object (
            [@attributes] =&gt; Array ( 
                [type] =&gt; integer 
                [nil] =&gt; true 
            ) 
        ) 
    ) 
    [6] =&gt; SimpleXMLElement Object ( 
        [date] =&gt; 2010-06-18 
        [description] =&gt; "TCDM1:WG'07 Outreach, upload list"
        [hours] =&gt; 0.25 
        [id] =&gt; 26376680 
        [person-id] =&gt; 2962280 
        [project-id] =&gt; 3652412
        [todo-item-id] =&gt; SimpleXMLElement Object ( 
            [@attributes] =&gt; Array (
                [type] =&gt; integer 
                [nil] =&gt; true 
            ) 
        ) 
    )
    [7] =&gt; SimpleXMLElement Object (
        [date] =&gt; 2010-06-18 
        [description] =&gt; "MGPJ1: Class of 2009 Anniversary, q/c, testing "
        [hours] =&gt; 0.25 
        [id] =&gt; 26371073 
        [person-id] =&gt; 2962280
        [project-id] =&gt; 3652412 
        [todo-item-id] =&gt; SimpleXMLElement Object ( 
            [@attributes] =&gt; Array ( 
                [type] =&gt; integer 
                [nil] =&gt; true 
            ) 
        ) 
    )
</code></pre>

<p>I want to extract distict value from given information.Here there is a sample of 4 entries,out of which 3 are of same person and 1 is of single person.So i want to extract the single distinct entry.
Pls help.I am new to php and not knowing the syntax properly.</p>
