Can someone tell me how the VB CAML Query would go to select the most recently created List item where 'FullName' field = 'Joe Smooth'.
Using Silverlight 5, SharePoint Client Object Model, VB.Net and a list called 'Staff'.
Thanks.
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It only takes a minute to sign up.
Sign up to join this communityCan someone tell me how the VB CAML Query would go to select the most recently created List item where 'FullName' field = 'Joe Smooth'.
Using Silverlight 5, SharePoint Client Object Model, VB.Net and a list called 'Staff'.
Thanks.
You can try either this:
<View>
<RowLimit>1</RowLimit>
<Query>
<OrderBy>
<FieldRef Name='Created' Ascending='False' />
</OrderBy>
<Where>
<Eq>
<FieldRef Name='Name' />
<Value Type='Text'>Joe Smooth</Value>
</Eq>
</Where>
</Query>
</View>
OR
<View>
<RowLimit>1</RowLimit>
<Query>
<OrderBy>
<FieldRef Name='ID' Ascending='False' />
</OrderBy>
<Where>
<Eq>
<FieldRef Name='Name' />
<Value Type='Text'>Joe Smooth</Value>
</Eq>
</Where>
</Query>
</View>
This should get you the last inserted item in a List