Sharepoint Search results are'nt items but List - search

With Sharepoint 2010 Server, I am Searching "toto" with a Basic Search Center WebPart.
Instead of retrieving items, I get lists.
Instead of get Url like http://server/Lists/myList/DispForm.aspx?ID=299777
I get an Url like http://server/Lists/myList/AllItems.aspx
Thanks in advance for your help.

Ok I'm New In Sharepoint. Trouble came with a crawling error.
Next time I'll see Craw Log before asking a Question.
the error was an Unexpected Token Error in the Site Data Web Service during Crawl.
trouble source is a white space in the Field Name of a column based on a termset
see : ... is an unexpected token. The expected token is '='

Related

Strange 'lastModifiedDateTime' object when requesting a sharepoint site with microsoft graph api

I am trying to detect sharepoint sites in Office 365 not visited last 180 days.
With this purpose I query sharepoint sites using a microsoft graph api query like this:
GET https://graph.microsoft.com/v1.0/sites?search=
which returns an JSON object where object['value'] is the first portion of site objects and object['#odata.nextLink'] is the link to the next portion of site objects (as I understand from what I see in the output)
When I view site objects which look like this:
'id': 'mytenant.sharepoint.com,29c17bd8-db42-430d-b5ba-b55d15885790,6302ea22-aa16-4e12-bd50-6e7094fc65cd',
'lastModifiedDateTime': '0001-01-01T08:00:00Z',
'name': 'TEST_MODIFIED_DATE',
'webUrl': 'https://mytenant.sharepoint.com/sites/TEST_MODIFIED_DATE',
'displayName': 'TEST_MODIFIED_DATE',
'root': {},
'siteCollection': {'hostname': 'mytenant.sharepoint.com'}}
in a loop I can see 'lastModifiedDateTime' property which may (or may not) be what I am looking for. Some sites and this one in particular have a strange value of 'lastModifiedDateTime':
'lastModifiedDateTime': '0001-01-01T08:00:00Z'
What does this strange datetime value mean?
Does it mean the last time the site was visited at all? It does not correspond with the value I can see in Sharepoint web interface ('last activity' column, which is now empty for this site)?
You can try using the 'id' that you have got from the search query and try to use that site id in the following query. https://graph.microsoft.com/v1.0/sites{siteid} You can get the right lastModifiedDateTime as shown below.
Please go through this document.

ViewPath query parameter in SharePoint list causes CSOM to fail Lists.GetById

It seems due to a recent SharePoint Online update that their lists (when selected using the left navigation) now adds a ViewPath query parameter by default. With this change, it seems like the Provider Hosted App redirect now sends a different ListId and not the Id for the actual list. When I use CSOM to resolve the ListId it results in a "Site Pages" and not the list at all.
clientContext.Web.Lists.GetById(ListId);
This code base did work before the recent SharePoint Online update but now I cannot call my list. If I manually remove the ViewPath query parameter from the list then the redirect shows the correct ListId and CSOM resolves the correct List. The problem is I cannot expect users to manually remove that query parameter.
If I navigate to the list by using the Site Content page and not the left navigation then this query parameter is not present and my application works.
Does anyone have context or direction into how to handle this new change?
I have a similar issue on our site. Instead of modifying the list, a script web part on the initial page seems to bleed through. I have ammended the links in the lefthand nav bar in an attempt to circumvent the viewpath query being added. I put in 2 url carriage returns on the end of the link. So far so good for me.

SharePoint 2013 Query for specific content type

I am trying to get the Search Content Web Part to display an aggregation of announcements from various announcement lists in a site collection.
I created the announcement lists using the "add an app" then "Announcements" so I am assuming that this is a list of the ContentType Announcement? I've added a new announcement to the list with a title of "this is a test".
After I have added the Search Content Web Part to a page (for test purposes a page in the same site as the announcement list) and gone to set the Query on the web part to:
ContentType:0x0104*
No results are being returned. To check that the announcement has been indexed by the crawler changed the query to:
Title:this is a test
Now two results are displayed 1 a csv and the other the announcement with a ending with ../DispForm.aspx?ID=1 .
Any help much appreciated.
Use ContentTypeId. I know that by default ContentType is shown this way, but it might be a bug. Just try ContentTypeId.

How does the Sitecore SharePoint Connector name its items?

Can anyone who has used the Sitecore SharePoint connector tell me how it chooses the name for the items it creates in the Sitecore tree?
I am able to map fields and sitecore values (such as __Displayname), but not the tree name.
The problem we face is that the data in SharePoint contains invalid characters that should not be allowed in the tree name.
Thanks in advance!
As far as I can see, SharePoint connector chooses Sitecore item name by iterating through the following SharePoint fields in that very order:
Title
LinkFilename
LinkTitle
NameOrTitle
URL
GUID
ID
If the field is not empty, its value is taken as an item name and the iteration stops. So you can find out where the invalid name comes from in your case. If it's NameOrTitle, for instance, then you can try to put a valid name to, let's say, Title and it should be picked by SharePoint connector.
I've never tried this myself, though. That's what I can judge about looking at the code.
Also, the documentation for SharePoint connector for Sitecore 6 is here.

Manager property is not available for Full Text Search (SharePoint 2010)

I had created a web part on MOSS 2007 which displays a organizational chart by searching (Full Text) the user profiles.
To identify the subordinates of a user, I used to search for users with the particular user in Manager property. The query looked like this:
SELECT AccountName, PreferredName, Manager, WorkEmail FROM scope() WHERE ("SCOPE" = 'People') AND Manager = 'domain\parent_user'
But, the same query does not run in SharePoint 2010 as Manager crawled property does not exists.
So, I created a new crawled property and mapped it to People:Manager(Text) now, the Manager property is always empty.
Even a full crawl after clearing the indexes also not helping.
Can anyone please help me in getting manager information in Full Text Search?
Thanks in advance!
Update: I tried mapping the crawled property with ows_Manager(Text) property also, still the same result.
After struggling a little, I got it working!
The new crawled property mapped to People:Manager(text) started giving values in search result by following the below steps:
Check Indexed checkbox in Manager User Profile property edit page
Reset crawl index
Full crawl again

Resources