Is there a way To Read and Write BLOB Data to sql server from access 2010 vba saving an excel file to sql server

Posted on 2016-08-17
Medium Priority
Last Modified: 2016-08-23
access 2010 vba
sql server 2008 r2

What I need:
vba saving an excel file to sql server

I have a filedialog making a single file selection.
Once i do that I need the file to store the Excel file in a sql server field.

Is there a way to do this ?

Question by:Fordraiders
  • 2
LVL 74

Accepted Solution

Jeffrey Coachman earned 2000 total points
ID: 41760210

Save the Excel "Data" to SQL, ...or store the Excel File as "Binary" data to SQL

Whats the ultimate need for this?
It might be easier to just store the Path to the Excel file.

In any event, you can use the "Steam" object in the newer versions of the ADO library for this:

It may not be "easy", as you hope...
Because any number of things may vary with your setup.
There may be conflicts/issues with:
Your Access version
Your Excel file format
Your version of SQL server
Your ADO library version

Lets see what others may post...


Author Closing Comment

ID: 41767128
considerations taken. Thanks !
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 41767409

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Windows Explorer lets you open cabinet (cab) files like any other folder. In VBA you can easily handle normal files and folders, but opening and indeed creating cabinet files takes a lot more - and that's you'll find here.
If you need to implement application level security in an Access database application or other VBA code, I strongly encourage you to take advantage of Active Directory groups.
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …

587 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question