9

Is it necessary that only a site column can be crawled and have a crawled property associated with it.

Can I have a custom column in a list and expect it to be available as crawled property.

Also, can I map multiple site columns to a single Managed property.

Edit:

The answer raises another question. What will happen if I have a custom column in 2 different lists(not created using site columns) with the same name. Is there a syntax for this naming convention?

3 Answers 3

7

Nothing is stupid here.

When you create a custom column in a list do a full crawl and you will see a crawled property available with the name ows_ColumnName.

You can't map a column to a Managed Property. You always map Crawled Properties to Managed Properties. So you will have crawled properties from site columns and the YES you can map as many crawled properties to a single Managed Property and Vice Versa. It's Many to Many Mapping.

Updated Answer: There is always this scene running as we have "Title" Column in all the lists(Custom). So if you create you own column in two different lists with same name it's not new.

To Be Noted: It's the search engine and Indexer responsibility to give back you accurate results. In the above case with two same column names in different Lists you will still have ONE crawled property as ows_ColumnName and ows_Title for OOB column. But you will see the items from different lists only. Crawled properties are only a blueprint they are not attached to a Single List. Mark My words.

10
  • 1
    If I'm not wrong, the ows_ColumnName is created if you add column to the list and create at least one item in the list.
    – Alexander
    Aug 8, 2014 at 7:28
  • I am not sure. But yes if crawler finds a Data only then it creates the property and i guess it makes sense else it's worthless. Aug 8, 2014 at 7:30
  • Just to clarify, the column is not a site column but a custom column which i created in a list. Even then a crawled property will be generated?
    – Saksham
    Aug 8, 2014 at 7:33
  • yes yes yes yes.. you just should have data in it as explained by @Alexander. Try it. Aug 8, 2014 at 7:34
  • Can you please modify your answer based on updated question?
    – Saksham
    Aug 8, 2014 at 7:39
3

The guys have given very thorough answers, to answer your final question about naming. For columns, avoid spaces in List Columns and Site Columns. For Managed Properties do not use dashes. For example do not use "My-Site-Column" as a Managed Property name. The query engine will misinterpret the "-".

0
2

I suggest you to use Site columns if you want to use the column in search. That way, and since SP 2013, it will create an automatic crawled and Managed property using a convention in the name. This link explains the convention: http://technet.microsoft.com/en-us/library/jj613136(v=office.15).aspx Also, this article is very good about how SP goes from site column to Managed property: http://blogs.technet.com/b/tothesharepoint/archive/2013/03/06/from-site-column-to-managed-property-what-s-up-with-that.aspx

About last question. If you create 2 different columns in 2 lists with the same name (not from Site columns), SP will create only one crawled property with same: ows_InternalColumnName so, if you map a Managed property to that crawled, and search using that property, you will get results from both lists. If you show the property in the search results, you'll get the proper value depending on the list item you are rendering.

1
  • +1. Thanks a lot for your input. I am using site columns and was just curious to know what would happen
    – Saksham
    Aug 8, 2014 at 9:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.