문제

I need to display the elements in Column "NetworkNodes" only SRV1 and SRV3 in Lookup, how to write correctly?

The remaining elements of the SRV are not needed.

Doesn't work like that:

Query = @"<Where><And><Eq><FieldRef Name='NetworkNodes' /><Value Type='Lookup'>" + "SRV1" + "</Value></Eq><Eq><FieldRef Name='NetworkNodes' /><Value Type='Lookup'>" + "SRV3" + "</Value></Eq></And></Where>"
도움이 되었습니까?

해결책

If the lookup column does not allow to select multiple values then you should try your query like:

<Where>
    <Or>
        <Eq>
            <FieldRef Name='NetworkNodes'/>
            <Value Type='Lookup'>SRV1</Value>
        </Eq>
        <Eq>
            <FieldRef Name='NetworkNodes'/>
            <Value Type='Lookup'>SRV3</Value>
        </Eq>
    </Or>
</Where>
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 sharepoint.stackexchange
scroll top