cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MeSan
Helper III
Helper III

Storing documents in SQL Server

Hello everyone,

I'm struggling to find a way of storing documents (.pdf, .docx or similar) in an SQL Server attribute Annual_report of type "varbinary(max)" in a table that exists in a database. 

Here is my problem in details :

I connected my SQL Server table with the App and added the attribute "Annual_report" to the form. I noticed that powerapps detects its type as Blob and not "varbinary(max)".. Then when added to the "Add new form" it doesn't give me the possibility to attach any file or add it ! quite weird.

So I have inserted this control inside the powerapps application to get its file/files and put them in the default value of the "Annual_report" field of the my form as u can see :

MeSan_0-1623415070160.png

this control I named it "annual_report_attached" and I tried to get its files using annual_report_attached.Attachments and gave it as a default value to the Annual_report attribute of my form but it shows me a data type conflict and errors I can't understand.. Is there any way I can do this please ? I just wanna the attached files of this control to be inserted into my sql field..

 

I highly appreciate your help !

Thanks in advance.

 

0 REPLIES 0

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (2,859)