Here is a simple function for constructing CAML Query if you have an array of strings. It is particularly helpful if the number of values(ie array length) is not constant.

If you want to create dynamic CAML query in JS, you can use below methods:
Helper method:




Posted By-
Satyam Kumar
Disclaimer: Developer’s Corner Section of ISHIR blog is contributed and maintained by independent developers. The content herein is not necessarily validated by ISHIR.
About ISHIR:
ISHIR is a Dallas Fort Worth, Texas based AI-Native System Integrator and Digital Product Innovation Studio. ISHIR serves ambitious businesses across Texas through regional teams in Austin, Houston, and San Antonio, supported by an offshore delivery center in New Delhi and Noida, India, along with Global Capability Centers (GCC) across Asia including India, Nepal, Pakistan, Philippines, Sri Lanka, and Vietnam, Eastern Europe including Estonia, Kosovo, Latvia, Lithuania, Montenegro, Romania, and Ukraine, and LATAM including Argentina, Brazil, Chile, Colombia, Costa Rica, Mexico, and Peru.
Get Started
Fill out the form below and we'll get back to you shortly.


