Skip to main content

I want to create Caml Query for following scenario, (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance")

(Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance"). I

I have tried but not able to create camlCAML query for same. I have used Caml designer for same but unable to get the proper result. Following

Following is the Caml Query which is generated by using Caml designer but it is not giving results

Author 1 Nitin Jagtap Program MBA Finance
<Where>
      <And>
         <And>
            <And>
               <Eq>
                  <FieldRef Name='Metadata_x0020_Name' />
                  <Value Type='Lookup'>Author 1</Value>
               </Eq>
               <Eq>
                  <FieldRef Name='Value' />
                  <Value Type='Text'>Nitin Jagtap</Value>
               </Eq>
            </And>
            <Eq>
               <FieldRef Name='Metadata_x0020_Name' />
               <Value Type='Lookup'>Program</Value>
            </Eq>
         </And>
         <Eq>
            <FieldRef Name='Value' />
            <Value Type='Text'> MBA Finance </Value>
         </Eq>
      </And>
   </Where>

I have a list having name “Metadata Values” which contains three columns,

  1. Content Name(Lookup column from Content List)
  2. Metadata Name(Lookup column from Metadata List)
  3. Value(Single line of text ) Each Content Namecontains has multiple metadata and values like below,

enter image description here

From above list I want to get Content Name which satisfy the condition (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

(Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

Please guide me regarding above scenario.

Any help will be appreciable.

Thanks, Nitin

I want to create Caml Query for following scenario, (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance"). I have tried but not able to create caml query for same. I have used Caml designer for same but unable to get proper result. Following is the Caml Query which is generated by using Caml designer but it is not giving results

Author 1 Nitin Jagtap Program MBA Finance

I have a list having name “Metadata Values” which contains three columns,

  1. Content Name(Lookup column from Content List)
  2. Metadata Name(Lookup column from Metadata List)
  3. Value(Single line of text ) Each Content Name has multiple metadata and values like below,

enter image description here

From above list I want to get Content Name which satisfy the condition (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

Please guide me regarding above scenario.

Any help will be appreciable.

Thanks, Nitin

I want to create Caml Query for following scenario,

(Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

I have tried but not able to create CAML query for same. I have used Caml designer for same but unable to get the proper result.

Following is the Caml Query which is generated by using Caml designer but it is not giving results

<Where>
      <And>
         <And>
            <And>
               <Eq>
                  <FieldRef Name='Metadata_x0020_Name' />
                  <Value Type='Lookup'>Author 1</Value>
               </Eq>
               <Eq>
                  <FieldRef Name='Value' />
                  <Value Type='Text'>Nitin Jagtap</Value>
               </Eq>
            </And>
            <Eq>
               <FieldRef Name='Metadata_x0020_Name' />
               <Value Type='Lookup'>Program</Value>
            </Eq>
         </And>
         <Eq>
            <FieldRef Name='Value' />
            <Value Type='Text'> MBA Finance </Value>
         </Eq>
      </And>
   </Where>

I have a list having name “Metadata Values” which contains three columns,

  1. Content Name(Lookup column from Content List)
  2. Metadata Name(Lookup column from Metadata List)
  3. Value(Single line of text ) Each contains has multiple metadata and values like below,

enter image description here

From above list I want to get Content Name which satisfy the condition

(Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

Please guide me regarding above scenario.

Any help will be appreciable.

Thanks, Nitin

Source Link

How to get complex scenario results using CAML in Sharepoint

I want to create Caml Query for following scenario, (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance"). I have tried but not able to create caml query for same. I have used Caml designer for same but unable to get proper result. Following is the Caml Query which is generated by using Caml designer but it is not giving results

Author 1 Nitin Jagtap Program MBA Finance

I have a list having name “Metadata Values” which contains three columns,

  1. Content Name(Lookup column from Content List)
  2. Metadata Name(Lookup column from Metadata List)
  3. Value(Single line of text ) Each Content Name has multiple metadata and values like below,

enter image description here

From above list I want to get Content Name which satisfy the condition (Metadata Name ="Author1" AND Value="Nitin Jagtap") AND (Metadata Name ="Program" AND Value="MBA Finance").

Please guide me regarding above scenario.

Any help will be appreciable.

Thanks, Nitin