I'm very sorry for the amateur question.

SQL Server 2012
Office files (Excel, Word, Powerpoint) and PDF files are stored in binary.
One file is registered on each line.

asp.net (Web Form)
List the tables stored in SQL Server with GridView control
When you press the button,
I want to open a binary file via a web browser.

I want to download Excel, PDF, etc. files stored in SQL Server.

Is there any source that can be helpful?

visual studio 2013 pro
sql server 2012
IIS server: Windows Server 2012 R2

It is also the first time that sql server handles binary files
asp.net (Web Form) It is also the first time to handle binary files with GridView.

I'm sorry for amateur questions. Nice to meet you.

  • Answer # 1

    Please understand that the following article has been read and written for the time being.

    How do I upload [ASP.NET] binary data and register it in the database?

    How to display binary data registered in [ASP.NET] database?

    I think that the structure of the SQL Server table is the same as the former article.

    In order to download properly, the information in the latter article is not enough (since it just displays an image), but it is basic to get data from SQL Server and write it to the response stream. Should be.

    If you don't understand this, there is no future story. If you understand, you may know how to download Excel or PDF. Please listen if you don't understand.

  • Answer # 2

    Unfortunately, binary files cannot be opened in a web browser