cancel
Showing results for 
Search instead for 
Did you mean: 

Microsoft Graph - SharePoint: Get Items in List is returning blank values for specific columns

Farzan10
Level 3

Hello,

I'm trying to use the web API Microsoft Graph - SharePoint and the action Get Items in List by Fields to retrieve values from a SharePoint table. However, the action is return values for most of the columns which are of "text" type but for some specific other ones, it is returning blank. I have a feeling it has got something to do with the type of data in that column so I need some help in understanding how to retrieve data of different types from SharePoint. 

@ewilson would you be able to share some insights on the Web API Service and how I could resolve this issue? Thanks in advance for your help.

Farzan10_0-1743546725473.png

This is the column (highlighted yellow) that is returning blank values even though on the browser you can see the name of a person.

6 REPLIES 6

ewilson
Staff
Staff

Hi @Farzan10 ,

That type implies it's an object definition and should be added to the Collection as a sub-collection. Can you see the raw JSON contents in the HTTP response data? If so, can you post that or DM me with it?

Cheers,
Eric

Farzan10
Level 3

Hi Eric,

Thanks for you response. I will DM you the HTTP Response Content.

Thanks,

Farzan

Neel1
MVP

@Farzan10 - Try to see in our output collection if you have something with name lookupID like shown below. then you need to get e-mail ID from this look up ID.

Neel1_0-1744021626472.png

Neel1_1-1744021663785.png

 

 

 

@Neel1 the issue is the specific field, from his SharePoint list, isn't being returned in the JSON response from Graph. We're looking into why that is.

Cheers,
Eric

Hi @Neel1, in addition to what @ewilson mentioned below, here is more context.

The SharePoint list has a column name called CP Contact Name (screenshot below). The SharePoint internal name for that column is CP_x0020_Contact but when I use the action Get Items in List to retrieve the items in the list, that particular column value is not returned. 
Farzan10_0-1744064471517.png

Having checked the HTTP Response Content with Eric, it seems that column name does not show up in the response content as well.

Here is the part of the Response Content which shows the fields from the SharePoint list, but as you can see, the CP Contact Name (CP_x0020_Contact) column is not present.

"fields":{"@odata.etag":"\"a4950df4-dee1-469f-b371-57ccdbd83196,2\"","ContentType":"Item","Modified":"2025-03-21T19:21:08Z","Created":"2025-03-20T19:05:42Z","AuthorLookupId":"15","Station":"Bensenville","Interchange_x0020_Location_x0020":"00498","I_x002f_C_x0020_Road":"CSXT","Train_x0020_ID":"646-958","Delete_x0020_train_x0020_after_x":"No","All_x0020_cars_x003f_":"Yes","CP_x0020_ContactLookupId":"1715","CP_x0020_Contact_x0020_Ph_x0023_":"1-630-860-4980","Other_x0020_Road_x0020_Contact_x":"Jim","Other_x0020_Road_x0020_Contact_x0":"Ousley","Other_x0020_Road_x0020_Contact_x1":"708-832-2088","Reason_x0020_for_x0020_TOL":"CSX not accepting train","NSC_x0020__x002d__x0020_TOL_x002":"TOL could not be issued - Business Exception sent NSC","id":"1","EditorLookupId":"1073741822","_UIVersionString":"2.0","Attachments":false,"Edit":"","ItemChildCount":"0","FolderChildCount":"0","_ComplianceFlags":"","_ComplianceTag":"","_ComplianceTagWrittenTime":"","_ComplianceTagUserId":"","AppEditorLookupId":"23"}}

 

 

Hi @Neel1, in addition to Eric's comment, here is more context on the issue.

The SharePoint list has a column called CP Contact Name (internally called CP_x0020_Contact) as shown below.
Farzan10_0-1744066545393.png

When I use the Microsoft Graph - SharePoint::Get Items in List action to retrieve all items from the list, the mentioned column above is not returned in the result. When Eric and I checked the Response Content from HTTP, we noticed that the specific column is also not present in the response content.

Here is the partial response content showing the fields of the SharePoint list, but as you can see, CP Contact Name (CP_x0020_Contact) is not present.

"fields":{"@odata.etag":"\"a4950df4-dee1-469f-b371-57ccdbd83196,2\"","ContentType":"Item","Modified":"2025-03-21T19:21:08Z","Created":"2025-03-20T19:05:42Z","AuthorLookupId":"15","Station":"Bensenville","Interchange_x0020_Location_x0020":"00498","I_x002f_C_x0020_Road":"CSXT","Train_x0020_ID":"646-958","Delete_x0020_train_x0020_after_x":"No","All_x0020_cars_x003f_":"Yes","CP_x0020_ContactLookupId":"1715","CP_x0020_Contact_x0020_Ph_x0023_":"1-630-860-4980","Other_x0020_Road_x0020_Contact_x":"Jim","Other_x0020_Road_x0020_Contact_x0":"Ousley","Other_x0020_Road_x0020_Contact_x1":"708-832-2088","Reason_x0020_for_x0020_TOL":"CSX not accepting train","NSC_x0020__x002d__x0020_TOL_x002":"TOL could not be issued - Business Exception sent NSC","id":"1","EditorLookupId":"1073741822","_UIVersionString":"2.0","Attachments":false,"Edit":"","ItemChildCount":"0","FolderChildCount":"0","_ComplianceFlags":"","_ComplianceTag":"","_ComplianceTagWrittenTime":"","_ComplianceTagUserId":"","AppEditorLookupId":"23"}}