CAMLQuery not working

Aug 11 at 9:20 PM
Edited Aug 11 at 9:21 PM
Hello,

I am trying to get the CAMLQuery to work and when I add the line in my code I get an error:

Error in function
SPServices.SPCascadeDropDowns
Parameter
relationshipListParentColumn: Customer
relationshipListChildColumn: Title
Message
Not found in relationshipList Order Items

Click to continue

Here is my code that works just fine if the CAMLQuery line is not included:

<html>
<head> <!--Include JQuery File--> <script type="text/javascript" language="Javascript" src="https://site.com/sites/mygym/SiteAssets/jquery-3.1.0.min.js"></script> <script type="text/javascript" language="Javascript" src="https://site.com/sites/mygym/SiteAssets/jquery.SPServices- 2014.02.min.js"></script> </head> <body>
<script language="javascript" type="text/javascript"> $(document).ready(function () { $().SPServices.SPCascadeDropdowns( { realtionshipWebURL: "https://site.com/sites/mygym/", relationshipList: "Order Items", relationshipListParentColumn: "Customer", relationshipListChildColumn: "Title", parentColumn: "Customer", childColumn: "Order Item", CAMLQuery: "<Eq><FieldRef Name='Item Status'/><Value Type='Choice'>Active</Value></Eq>", debug: true }); }); </script> </body>
</html>

Any help would be greatly appreciated
Coordinator
Aug 12 at 4:39 PM
So this works just fine without the CAMLQuery line? It's look OK to me, but you might want to check whether you're getting any items back from the call.

M.
$().SPServices.SPCascadeDropdowns( {
 realtionshipWebURL: "https://site.com/sites/mygym/",
 relationshipList: "Order Items",
 relationshipListParentColumn: "Customer",
 relationshipListChildColumn: "Title",
 parentColumn: "Customer",
 childColumn: "Order Item",
 CAMLQuery: "<Eq><FieldRef Name='Item Status'/><Value Type='Choice'>Active</Value></Eq>",
 debug: true
});