Quantcast
Channel: SharePoint 2013 - Development and Programming forum
Viewing all articles
Browse latest Browse all 7589

Why REST API does not give me values in "Name" column?

$
0
0

Hi,

I'm using Sharepoint 2016, I have a Document Library with name "test doc lib", and uploaded some files. The list looks like below,

Now I want to use REST API to get all files in this lib, I put this in the url in Chrome,

http://myrooturl/_api/web/lists/getbytitle('test%20doc%20lib')/items

But in the returned xml data, I don't see the names (e.g. "ToR Update" for the second file).. 

One of the entries returned is like this:

<entry m:etag="&quot;1&quot;">
<id>c07fc9c5-1cbb-478a-9b7b-f610dc932711</id>
<category term="SP.Data.Test_x0020_doc_x0020_libItem" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<link rel="edit" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/FirstUniqueAncestorSecurableObject" type="application/atom+xml;type=entry" title="FirstUniqueAncestorSecurableObject" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/FirstUniqueAncestorSecurableObject" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/RoleAssignments" type="application/atom+xml;type=feed" title="RoleAssignments" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/RoleAssignments" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/AttachmentFiles" type="application/atom+xml;type=feed" title="AttachmentFiles" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/AttachmentFiles" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/ContentType" type="application/atom+xml;type=entry" title="ContentType" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/ContentType" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/GetDlpPolicyTip" type="application/atom+xml;type=entry" title="GetDlpPolicyTip" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/GetDlpPolicyTip" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/FieldValuesAsHtml" type="application/atom+xml;type=entry" title="FieldValuesAsHtml" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/FieldValuesAsHtml" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/FieldValuesAsText" type="application/atom+xml;type=entry" title="FieldValuesAsText" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/FieldValuesAsText" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/FieldValuesForEdit" type="application/atom+xml;type=entry" title="FieldValuesForEdit" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/FieldValuesForEdit" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/File" type="application/atom+xml;type=entry" title="File" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/File" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/Folder" type="application/atom+xml;type=entry" title="Folder" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/Folder" />
<link rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/ParentList" type="application/atom+xml;type=entry" title="ParentList" href="Web/Lists(guid'6ced7d41-4480-4a73-85e2-99fff7ae0a4b')/Items(1)/ParentList" />
<title />
<updated>2019-01-30T20:28:27Z</updated>
<author>
<name />
</author>
<content type="application/xml">
<m:properties>
<d:FileSystemObjectType m:type="Edm.Int32">0</d:FileSystemObjectType>
<d:Id m:type="Edm.Int32">1</d:Id>
<d:ID m:type="Edm.Int32">1</d:ID>
<d:ContentTypeId>0x01010088EBA4AD78FEF3419C77AD257C7DD36C</d:ContentTypeId>
<d:Created m:type="Edm.DateTime">2019-01-30T19:16:50Z</d:Created>
<d:AuthorId m:type="Edm.Int32">10</d:AuthorId>
<d:Modified m:type="Edm.DateTime">2019-01-30T19:48:54Z</d:Modified>
<d:EditorId m:type="Edm.Int32">10</d:EditorId>
<d:OData__CopySource m:null="true" />
<d:CheckoutUserId m:null="true" />
<d:OData__UIVersionString>1.0</d:OData__UIVersionString>
<d:GUID m:type="Edm.Guid">e9b4a53b-d49c-4035-9954-ea4d0f4f3883</d:GUID>
<d:Title m:null="true" />
</m:properties>
</content>
</entry>

How do I retrieve the "displayed values", eg. "1.1 ToR Update", "44 minutes ago" etc?

thanks!


Viewing all articles
Browse latest Browse all 7589

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>