method for querying list data
1
vote
1answer
444 views
How do I select only top level folders using CrossListQueryCache?
I want to select the list of folders (without subfolders, not recursive) of a Document library using CrossListQueryCache.
Everything is working fine except that i am receiving ALL the folders and ...
2
votes
3answers
2k views
Querying for Approved (Published) List Item Data
My scenario:
I have a page layout that has a user control on it. This user control queries data contained in other pages within the site collection to show a summary of related information. Anonymous ...
0
votes
3answers
2k views
How to select MAX field in CAML query
RowLimit seems not working. I'm using it in CAML query to run a SSRSreport. I have to pick the Max date for each user. i sorted the user as descending and set the RowLimit element as 1. But that does ...
0
votes
1answer
356 views
External CT Related Lists - Examples - CAML - LINQ to SharePoint
I'm trying to return related data via External Content Types. I was wondering which is better to use, CAML queries or LINQ to SharePoint? I'm fine with writing CAML queries besides the relating part ...
3
votes
3answers
509 views
SharePoint 2010 equivalent to SQL Profiler?
Is there a way to view the CAML that is running on a SharePoint 2010 installation?
A bit like how you can monitor SQL running on a database with MS-SQL Server - is this possible with CAML and ...
1
vote
3answers
757 views
Showing the current user's tasks in a Content Editor Web Part using JQuery
I have been searching this site for an answer but I have been unable to find anything that will work.
I have been trouble pulling the tasks of the current user from a subsite. I am using SharePoint ...
6
votes
2answers
2k views
Can I order by Content Type in a CAML query?
Is it possible to order by content type in a CAML query?
I seem to always get the same result no matter what I do with the Order by. Ordering by ID instead works perfectly.
query.Query = @"
...
0
votes
1answer
1k views
CAML get list by view name
I'm making an Ajax call to the Lists web service to retrieve some items. I'd like to return results only from a specific view. Can I do that through CAML?
I have this so far - which the attribute ...
5
votes
2answers
4k views
CAML Query with Date Range
I'm writing an SPSiteDataQuery and I am having issues with the Query property. I need to return all results where the Record_x0020_Yr_x0020_End_x0020_Date is between 12/31 of the current year and 90 ...
3
votes
1answer
2k views
How do I query a list using CAML and SPQuery?
I have a SPList but I don't need to go through everything in that list. I need to establish a CAML query so I can limit the list items. Then, go thru each item from the query result and do something. ...
5
votes
2answers
718 views
Problem with CAML SPQuery ItemChildCount result
I know that this query works fine
SPQuery query = new SPQuery();
query.Query = "<OrderBy><FieldRef Name='ItemChildCount' Ascending='FALSE' /></OrderBy>";
But my ...
1
vote
1answer
516 views
CAML Query for two reference fields that point to the same SharepointID
I've got a SP2007 list (List A) with two reference-fiels (Column 1; Column 2) that reference items from a different list (List B). For some Opalis automation I need a CAML Query that gives me the ...
1
vote
2answers
3k views
Create CAML SPQuery to order by ItemChildCount in descending order
How do I create a CAML query to display all items on the list order by ItemChildCount?
Somewhat like this:
Select *
from table
order by itemChildCount descending
1
vote
4answers
1k views
CAML query to find a value that does not begin with
I want to build a CAML query to search for all title fields that do NOT begin with a certain value:
something like this: Where Title NOT BeginsWith 'myvalue'.
How can i do that in my CAML query?
2
votes
1answer
2k views
What does the GetListItems query option IncludeMandatoryColumns do?
I found myself working with the Lists.GetListItems method fairly often. Unfortunately, I have never understood what the IncludeMandatoryColumns query option actually does. The documentation seems to ...
7
votes
3answers
2k views
SharePoint 2010 CAML Query fails when indexed columns used
I have an SPQuery that has been working fine until my list hit 500 items:
q.Query = "<Where><Eq><FieldRef Name='DefectID' /><Value Type='Counter'>" + DefectID + ...
2
votes
3answers
2k views
Problem using viewFields to return more fields
Do I have to put a prefix of ows before retrieving fields? because I am trying to obtain additional fields and not being able to?
soapEnv += "<listName>My SP List</listName>";
...
2
votes
2answers
364 views
DefaultValue for CAML Variables
I have a question sort of related to this post. The default value of the CAML variable UserID is the CurrentUserName. Can that be set to different properties or is that fixed? For example, could ...
3
votes
2answers
4k views
GetListItems Lists.asmx and Meta Data Columns
I'm trying to use the GetListItems web service in MOSS 2007 to return all the columns and rows in custom SharePoint list. I don't need to filter any of the data, so I've left the QueryOptions and ...
0
votes
1answer
434 views
PreSaveAction and CAMLQuery
I'm cross posting this from Stump the Panel for some more visibility from a wider developer base.
I'm trying to create a script I'll eventually adapt into a PreSaveAction, but I'm running into a ...
1
vote
1answer
508 views
Does an indexed column need crawling?
I am new to SharePoint and was struggling to get this particular information. Please could anyone explain:
Will configuring the shared service provider to crawl the content make CAML queries faster?
...
1
vote
1answer
923 views
How to get checked out SPListItem for current user by file name using CAML query?
I use SharePoint 2010 RTM and now I'm trying to get SPListItem, which was checked out by current user, using code like this:
query.Query = "<OrderBy>" +
...
1
vote
2answers
2k views
Caml Query for Order By List for web service call not ordering
I'm calling web service List.asmx using Jquery and getting results using this but its not ordering by DisplayOrder. This is the caml query.
<soapenv:Envelope ...
2
votes
2answers
845 views
How do I test if I will be able to execute a query (does the site exist)
When I run a (CAML based query) executeQuery against Sharepoint, sometimes the site does not exist (it is created by a workflow process which may not have run). When this happens, I get a ...
7
votes
1answer
1k views
Why is my CAML query working in CAML Builder but not in the application?
I have a CAML query that queries a calendar list and I want it to return all the items in the list with an EventDate of today or later, ordered in ascending order. The CAML query I'm using is this:
...
1
vote
1answer
642 views
Can I get the list of files for two or more directories?
My current query is below and works adequately enough.
The sharepoint developer is creating a workflow that will look at files in the "Documents" folder, and if it certain flags are set, the ...
5
votes
5answers
952 views
When I execute a CAML query, how do I know what ListItem details I can include?
I was querying a SharePoint library, trying to retrieve some file attributes. Apparently some things like FileType and Date are not supported, even though those fields are listed as a built in field. ...
3
votes
6answers
3k views
How to query using CAML when a value has < in the value
I'm using SPServices to query a list, using CAML, and the column I'm searching (Title) have values that contains < and >.
Is there anyway I can use CAML to find these values? It seems that I'm ...
4
votes
1answer
500 views
Problems with customizing Ribbon for webparts with “Summary Toolbar”
I have a problem with customizing Ribbon for webparts with "Summary Toolbar". I add the button through CAML code. (Generated by SPSF, but shouldn't matter)
My buttons shows up when viewing the list ...
6
votes
1answer
4k views
CAML query builder that supports inner joins?
I'm Looking for a query builder that can assist me in creating CAML queries that will contain inner joins.
Does anything like this exist?
Update: To ask my question more clearly, I am looking for a ...
0
votes
1answer
712 views
CAML >> Keep getting “one or more fields are not installed properly”
when I debug i can see URL is valid (like below). Shared Documents is tie a to custom content type.
string fileURL = "Shared Documents/Marketing Folder/Sales_Report.txt";
oQuery.Query = ...
4
votes
1answer
3k views
CAML query with more than multiple AND/OR generates SPException “One or more field types are not installed properly. Go to the list settings page to delete these fields.”
I need to build a CAML query at runtime based on user input. The CAML query could be as simple as
<Where>
<Eq>
<FieldRef Name="Status" />
<Value ...
0
votes
1answer
198 views
CAML > get item by it's URL
Should this CAML be working. (I tried it with u2u and it does not display the URL column.) I get this error. {System.ApplicationException} = {"One or more field types are not installed properly. Go to ...
2
votes
3answers
899 views
CAML Query Maximum Size
I am running a sharepoint caml query where I want to check that a field on an item is equal to one of many values. I do this dynamically and may wish to check against many hundreds of values.
I found ...
0
votes
1answer
283 views
caml query help
I'm building a webpart that queries an sp list. my list contains two fields (title, tip).
title = is a single text line and
tip = a yes/no check box
currently in my code, i am calling all items in ...
1
vote
1answer
346 views
CAML Query get elements with most recent created date
I'm trying to get the elements with the most new created date using CAML query in sharepoint 2007.
I can do it using:
"<OrderBy><FieldRef Name='Created' Ascending='False' ...
0
votes
3answers
6k views
CAML, get all list items where text field contains a value?
I would like to use CAML to write an efficient query to get all items in a list where a text field contains a value...
for example:
**ID Name**
123
234 ...
2
votes
1answer
2k views
ClientContext + camlQuery.ViewXml
I use SP Client and want to return ListItemCollection which will be filled with items from specific view which I choose. I get ViewQuery string by sending view index in viewcollection. Problem is in ...
0
votes
1answer
683 views
Sharepoint 2010 ALERT settings - customize possible set of lists
I want to customize possible set of lists on which user can set "alerts ON".
Customizing just ribbon button ("Alert me") for not showing on specific list isn't enough because - on some list on which ...
1
vote
1answer
427 views
CAML or C#: Change the URL of “Edit Item” of Custom List item
How can I change the target URL of "Edit Item" option of a custom list in CAML or .net?
2
votes
1answer
1k views
CAML 'Endswith' equivalent?
I have to pull the data from the custom list by using a CAML query.
I would like to use the "Endswith" option in the CAML query however it seems to be unsupported in sharepoint 2007.
What would be ...
1
vote
2answers
576 views
CAML Returning Tomorrow's Value when filtering Today
I have the following CAML query for SP2003
SPQuery qry = new SPQuery();
qry.ExpandRecurrence = true;
qry.CalendarDate = DateTime.Now.Date;
qry.Query = ...
0
votes
1answer
771 views
How do I determine the CAML equivalent for a SQL query?
I want to write an equivalent CAML query for the given SQL Query below:
select top 10 * from TestTable where ItemID in ( select top 10 ItemID from TestTable order by Views desc) order by UserName ...
0
votes
1answer
162 views
CAML to search column name
I'm looking to search within each list for a column. The problem is that this column is referred to differently in CAML. Look at this for a detailed explanation:
...
2
votes
1answer
745 views
How can I use managed metadata field in the where clause of CAML?
How can I use managed metadata field in the where clause of CAML?
2
votes
2answers
727 views
CAML OrderBy and managed metadata
I have something like this:
SPQuery query = new SPQuery();
query.Query = "<OrderBy><FieldRef name=\"MyTerm\" /></OrderBy>";
myList.GetItems(query);
I can sort on normal fields, ...
0
votes
4answers
3k views
How can I Create a join between two sharepoint custom list using CAML Query?
Will you please provide me help to create a join between two SharePoint lists using CAML Queries. I am using SharePoint 2010 Development Platform. Thanks in advanced.
0
votes
1answer
98 views
Retrieving lists from sharepoint site
I am trying to retrieve lists from a sharepoint site. I know how to do it using web services. However, the requirement is that I need to use Xelement GetList and the output should have PropertiesXML ...
4
votes
3answers
2k views
How to get last major published version?
I am trying find exact CAML query, or other possible way in code to find out
"The last major published version" (not necessarily the latest)?
2
votes
1answer
585 views
Nested CAML Querie results in exception “ Some part of your SQL statement is nested too deeply. Rewrite the query or break it up into smaller queries”
All,
I am trying to mimic SQL"IN" operation using CAML. Lets take a scenario where we need fetch all the ListItems with ID within a list of IDs. The target list is realy large ( 50k records)
...

