Forum Discussion
Accessing SQL Blobs
Hi:
An ERP application stores document attachments in SQL as Blobs.
Is it possible for Power BI to access attachments for those who want to open, say, PDFs in a Power BI dashboard or report? If so, how?
Thank you!
John
Yes, Power Query has a "Binary" data type that you can then bend to your will, for example by declaring that you want to read that binary as a PDF.
Just add the blob to your SQL view columns.
Here's an example where I pull a bunch of CSV files out of their blobs (the [Content] column)
#"Invoke Custom Function1" = Table.AddColumn(#"Renamed Columns1", "CSV", each #"Get CSV file"([Content])),
via a custom function where I do some basic transforms:
Get CSV File =
(File) => let
Source = Csv.Document(File,[Delimiter=",", Encoding=1252, QuoteStyle=QuoteStyle.Csv]),
#"Promoted Headers" = Table.PromoteHeaders(Source, [PromoteAllScalars=true]),....
- Anonymous6 years ago
Thank you. I apologize, for getting upset.
How can that, at least, be done? I cannot find any good and clear instructions on doing so.
13 Replies
- lbendlinSuper User
Yes, Power Query has a "Binary" data type that you can then bend to your will, for example by declaring that you want to read that binary as a PDF.
Just add the blob to your SQL view columns.
Here's an example where I pull a bunch of CSV files out of their blobs (the [Content] column)
#"Invoke Custom Function1" = Table.AddColumn(#"Renamed Columns1", "CSV", each #"Get CSV file"([Content])),
via a custom function where I do some basic transforms:
Get CSV File =
(File) => let
Source = Csv.Document(File,[Delimiter=",", Encoding=1252, QuoteStyle=QuoteStyle.Csv]),
#"Promoted Headers" = Table.PromoteHeaders(Source, [PromoteAllScalars=true]),....
- AnonymousNot applicable
Hi:
You mentioned "Power Query". What about Power BI?
John
- AnonymousNot applicable
Frankly, I don't understand any of what you said. Can you please supply some simple steps? Does this sort of thing require prorgramming? Can you not view the PDF attachments in Power BI?
- lbendlinSuper User
Power BI is a Data Analytics tool, not a picture viewer. There is a PDF visual somewhere but I think it is broken/unsupported.
What Power BI (Power Query) offers is a way to extract data from PDF files, like table data etc.
- v-xicaiCommunity Support
Hi Anonymous ,
You may refer to the article: How to access data from Azure Blob Storage using Power BI.
Best Regards,
Amy
Community Support Team _ Amy
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- AnonymousNot applicable
Thanks, Amy!
Would the same thing work for PDFs, as well as CSVs?
John
- viktorglezNew Member
There is another alternative that may interest you to solve the problem,
Indirectly you can create an extractor externally (by programming it) to read the blob and build the file temporarily then you could reach that file through a link for that record:
You have this:
Then: