0

I have a database in MS Access and I need to link some cell in MS Excel.

I need to link only few cells from a huge table that I update automatically.

Maybe it is easy but I know how to import table from access but I do not find a way to link a single cell

I need that the solutions works in the same way on MS Excel 2007 and on MS Excel 2016

1 Answer 1

2

One way:

In Excel, go to the Data tab > Get External Data > From Other Sources > From Microsoft Query

From there, uncheck "Use the Query Wizard to create/edit queries" (this is because the query wizard doesn't appear to let you put criteria on a field without also Selecting it) and find you access database. From this screen, you can either type the SQL for your query, or use the tools to create it. To add fields, double click the names in the "table pane" which should appear by default and to add criteria, click the "glasses with filter symbol" button and add criteria in the new pane.

If you want a specific few cells, one approach is to add only the columns you want as fields, and then use criteria to single out the records you want. Once you have the query designed, just close the window with the X in the top right, this will bring up the "Import Data" prompt. Import as a table in the place where you want the cells to appear. Now you have a set of cells linked to an Access database and if your query is designed correctly, they will be the specific cells you want.

Here are some images that might be helpful

This is my original table for reference (double clicked * so every column appeared)

enter image description here

From here, click add the criteria pane

enter image description here

Add a criteria based on a primary key that will restrict you to only the records you want (keep adding "or" rows if you want multiple rows)

enter image description here

Then, if you imported every column and not just the ones you want, click each header and delete them (just removes them from query).

![enter image description here

Now I only have the "Height" column for the row with ID 4.

If you don't want a whole table with headers for one cell, go to the TableTools/Design tab and uncheck the box called "Header Row" in the Table Style Options section. This will remove the header row and you will have just a few cells that update automatically from your access database.

You may want to protect these cells, since it seems like you can just overwrite them if you want. The part of the table that is referenced to the database will fix themselves when the table is refreshed, but if rows or columns are added to the table, they will remain.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .