Let's POWER Automate

From no-code to low-code

Menu
  • Expressions
  • Filters
  • General
  • Application specific solutions
    • Dataverse
    • Excel
    • Forms
    • Planner
    • Outlook
    • SharePoint
    • Teams
  • Triggers
  • Resources
  • ABOUT ME
  • Get help with your flow
Menu

Get schema for a new SharePoint column with Power Automate

Posted on May 3, 2023May 3, 2023 by Tom

“I’d like to create a new SharePoint column with a Power Automate flow, is there some easy way to define its schema, e.g. using SP interface?”


There’s an older article explaining how to create a new SharePoint column from a Power Automate flow. You prepare the column schema, use it in the HTTP request, and a new column is created. While it’s just a few steps, the first one can be a tricky one. How do you create the column schema? How to define all the properties of the new column? Do you have to understand all the properties and set them all manually?

Get the schema from an existing column

While preparing the XML manually is one of the options, it’s not an easy one. Luckily, as many times before, you can use the existing user interface to do some work for you. In this case we’re talking about the preparation of the column schema.

Firstly, prepare the column exactly as you want it in some SharePoint list. It can be a separate SharePoint list that’ll just help you define all the column properties.

Secondly, use the HTTP request to SharePoint below to extract the column schema.

Method: GET

Uri:
_api/web/lists/getByTitle('<listName>')/fields/getByTitle('<columnName>')/SchemaXML

Note: <…> are placeholders, replace them including the < and >.

Extract the schema with an expression and use is to create copy of the column.

body('Send_an_HTTP_request_to_SharePoint')?['d']?['SchemaXml']
Power Automate SharePoint column schema

And the last step could be adding the column to a view.

Summary

As you can see, even a seemingly complicated task as creating schema of a SharePoint column can be simplified if you know what HTTP request to use in your Power Automate flow. You can create the column using the SharePoint interface, set all its properties by a few clicks, and then just extract its schema with the HTTP request above. The only prerequisite being that you must be avare that such HTTP request exists, which is the reason why I created the HTTP requests to SharePoint cheat sheet.


Do you struggle with the various expressions, conditions, filters, or HTTP requests available in Power Automate?

I send one email per week with a summary of the new solutions, designed to help even non IT people to automate some of their repetitive tasks.

All subscribers have also access to resources like a SharePoint Filter Query cheat sheet or Date expressions cheat sheet.

Zero spam, unsubscribe anytime.

2 thoughts on “Get schema for a new SharePoint column with Power Automate”

  1. Mark Adkins says:
    May 8, 2023 at 6:16 pm

    Can you do some articles that aren’t Sharepoint related? I think Power Apps is becoming more and more of an enterprise app building tool. Maybe how to work with Facebook Messenger (or other PVA chat channels) or how to build complex PVA flows and the gotchas

    Reply
    1. Tom says:
      May 28, 2023 at 3:00 pm

      Hello Mark,
      I might do some in the future if I meet a customer who’s interested in such things, but so far Power Automate and SharePoint is what interests most people.

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Do you know what to do, but not how to do it?

Get The Ultimate Power Automate expressions cheat sheet and translate your thoughts into flows with ease!


There's also the HTTP requests to SharePoint cheat sheet to help you overcome limitations of some standard actions!

Do you struggle with the various expressions, conditions, filters, or HTTP requests available in Power Automate?

I send one email per week with a summary of the new solutions, designed to help even non IT people to automate some of their repetitive tasks.

All subscribers have also access to resources like a SharePoint Filter Query cheat sheet or Date expressions cheat sheet.

Zero spam, unsubscribe anytime.

Didn't find what you were looking for?
Need to adjust a solution to fit your needs?
Or would you just like to get an assistance from somebody with 1000s of hours of experience with Power Automate?

Power Automate blogs worth visiting

Damien Bird
Dennis (Expiscornovus)
Paul Murana

©2023 Let's POWER Automate | Theme by SuperbThemes