Forum Discussion

Richard Collins's avatar
Richard Collins
Copper Contributor
Apr 23, 2018

Can a variable be coded in CAML powershell for Sharepoint online?

$Items = Get-PNPListItem -List 'ListBB' -Query <View><Query><Where><Eq><FieldRef Name='fueltype'/><Value Type='Text'>$dresda</Value></Eq></Where></Query></View>

 

Is there a way that $dresda field assigned from another list item can be passed to the query? The objective is to read all the items in ListAA retrieve and update the matching one in ListBB