1

In the Sharepoint website, I have a list called 'publication groups', whose contenty type is A.

I use this url to get the properties of a item. https://something.com/myweb//_api/web/lists/getbytitle('publication groups')/items?$filter= Title eq 'Sunday'

I find in the xml result, it doesn't contain some field of this item. Actually A content type contains a field called Project, but I cannot get this field in the xml.

Is there anywhere to set the configuration? Thanks.

Edit:

I tried with this url: https://something.com/myweb//_api/web/lists/getbytitle('publication groups')/items?$filter= Title eq 'Sunday'&$select=*,Project Then I got this error

enter image description here

I went to the content type setting to see what fields it includes, but I see project there. What may be wrong? Why cannot I get this field if it belongs to Publication group?

enter image description here

Edit2:

I resolved this problem. Why I get the "The field or property project does not exist" error is that I should use the internal name of project field, not the show name. The url should be like this: https://pubcenter-dev1.sp.srv.volvo.com/robinlab//_api/web/lists/getbytitle('publication%20groups')/items?$select=vppc_ProjectLookupId

Firstly, I need to get the internal name of this project field.

6
  • Try using https://something.com/myweb//_api/web/lists/getbytitle('publication groups')/items?$filter= Title eq 'Sunday'&$select=*,Project
    – Akhoy
    Jul 31, 2015 at 9:07
  • Hi. I notice that you add '$select=*,Project' at the end of the url. Is it poject not included in * ? I suppose that * means it shall return every field of the item.
    – Sun Robin
    Aug 3, 2015 at 2:56
  • Yes, * is for selecting all items. Even after selecting all items, some items are not returned due to performance reasons. That is why, Project column is explicitly selected.
    – Akhoy
    Aug 3, 2015 at 5:01
  • Hi, uberz91. Thanks very much. But now I could still not get the project field in the response xml file. Could please see my edit? Thanks!
    – Sun Robin
    Aug 3, 2015 at 5:19
  • Hi uberz91. Can you move your comments to the Answer area, so I can mark it as Answer?
    – Sun Robin
    Aug 3, 2015 at 5:54

2 Answers 2

2

Use https://something.com/myweb//_api/web/lists/getbytitle('publication groups')/items?$filter= Title eq 'Sunday'&$select=*,Project. Judging from OP's edit, apparently, Project wasn't the internal name of the field. Using the correct internal name gave the results.

1

You have to mention name of fields which you want to get in result in parameter $select

Example

_api/web/lists/getByTitle('Languages')/items?$select=Title,LanguageScope,LanguageType

Source: Link

1
  • Hi Khamar. As I suppose, if I don't use the select key word, it should return all the fields of the items. Is it wrong???
    – Sun Robin
    Aug 3, 2015 at 2:53

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.