Skip to content

Instantly share code, notes, and snippets.

@cbaragao
Created August 5, 2025 17:50
Show Gist options
  • Select an option

  • Save cbaragao/109d9713308c0df2d1d77f7acf639d8a to your computer and use it in GitHub Desktop.

Select an option

Save cbaragao/109d9713308c0df2d1d77f7acf639d8a to your computer and use it in GitHub Desktop.
(sharepoint_site as text, list_title as text) =>
let
Source = Record.SelectFields(
OData.Feed(
sharepoint_site & "/_api/lists/getbytitle('" & list_title & "')",
null,
[Implementation = "2.0"]
),
"Fields"
)[Fields],
Select_Columns = Table.SelectColumns(
Source,
{"Id", "Title", "InternalName", "Indexed", "Required", "TypeDisplayName", "CanBeDeleted"}
),
Set_Types = Table.TransformColumnTypes(
Select_Columns,
{
{"Id", type text},
{"Title", type text},
{"InternalName", type text},
{"Indexed", type text},
{"Required", type text},
{"TypeDisplayName", type text},
{"CanBeDeleted", type text}
}
)
in
Set_Types
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment