web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Getting listitem attac...
Power Automate
Answered

Getting listitem attachments using OLEDB 12.0

(0) ShareShare
ReportReport
Posted on by 158

Hello:

 

I have built a Power Dektop Flow where I get fields of Microsoft List using OLEDB 12.0. Follow this link to get connection string:

 

https://www.connectionstrings.com/sharepoint/

 

Then use Open SQL connection

After that use Execute Query SQL and make a select of the name of list. Ex : select * from ['Tràmits']

 

Finally you are able to get all field values of that list, iterating results

 

For each CurrentItem in QueryResult

 

CurrentItem2['Title'] - You get title field

 

The problem I have, is that using this method I am not able to get listitem attachments.

Anyobody knows how to get them?

 

I need to get FileAttachments path and filename name.

 

I don't want to use Sharepoint connector in Power Automate Desktop.

 

Thanks in advance.

 

Francesc

 

  • Verified answer
    Agnius Bartninkas Profile Picture
    Most Valuable Professional on at

    I don't think you can get it via a SQL connection like this. Is this an on-premise SharePoint? If it is MS365 SharePoint, you can probably use the Graph API to get what you need. See here for some references: https://learn.microsoft.com/en-us/graph/api/resources/sharepoint?view=graph-rest-1.0

     

    Using the SharePoint connector would definitely make this easier. I assume the reason you don't want to use it is because you are using a free license of PAD?

    -------------------------------------------------------------------------
    If I have answered your question, please mark it as the preferred solution. If you like my response, please give it a Thumbs Up.

    I also provide paid consultancy and development services using Power Automate. If you're interested, DM me and we can discuss it.

  • francescjp Profile Picture
    158 on at

    Hello @Agnius :

     

    I have asked to my tenant administrator for one token to make graph calls, in order to get lists attachements.

    Thank you very much.

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 273 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 235

#3
David_MA Profile Picture

David_MA 172 Super User 2026 Season 2

Last 30 days Overall leaderboard