473,387 Members | 1,528 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Updating Access using Excel spreadsheets used to distribute Access info

3
The volunteer organization I work with maintains an Access database of its members. Periodically, geographically specific member lists with portions of each member’s information (the balance is confidential) are distributed to geographically specific coordinators in the form of Excel spreadsheets. While using their member lists, the coordinators learn of updates to the information about members in their area and make changes to the spreadsheets they have received.

Is there a simple and reliable way for the central Access database to be updated using the changed spreadsheets the coordinators create and avoiding duplicate data entry? Please understand that the organization has no IT personnel, so the process would need to be very straightforward.

Thank you
May 15 '12 #1
7 8014
nico5038
3,080 Expert 2GB
Excel sheets can be linked as a table and used for input.
It's however very risky, as datatype problems are common (erroneous cell definition after copy/paste) and you'll need a unique ID to identify the row in the original table.
Thus I would probably create such a linked table and show the differences, to update the fields manually.

Nic;o)
May 15 '12 #2
dchyde
3
Thanks for your response, Nic;o). What I gather from your response is that for confidence and accuracy, the Access database should be maintained manually.

If coordinators simply make note of the changes they are making to their Excel member lists and forward just the changes to the central office that maintains the Access database for manual entry, that would be the same result, correct?
May 15 '12 #3
zmbd
5,501 Expert Mod 4TB
dchyde:

You may want to take a look that transfersheet method:

http://msdn.microsoft.com/en-us/libr...ice.12%29.aspx
...You can use the TransferSpreadsheet method to import or export data between the current Access database or Access project (.adp) and a spreadsheet file...
Normally, I've used this to push the data out of the database such as in the following:
Expand|Select|Wrap|Line Numbers
  1. Sub zj_excel_query2sheet_1()
  2. Dim filename As String, qryout As String
  3. fileName = "C:\Documents and Settings\All Users\Workbook1.xlsx"
  4. qryout = "Query1"
  5. DoCmd.TransferSpreadsheet acExport,acSpreadsheetTypeExcel12Xml, qryout, fileName, True
  6. End Sub
Using this, you will get a workbook with a worksheet named "Query1" and it would look like:


The first row has the field names as the header.

Now I ran this as an import.
Expand|Select|Wrap|Line Numbers
  1. Sub zj_excel_sheet2tablet_1()
  2. Dim fileName, qryout As String
  3. fileName = "C:\Documents and Settings\All Users\Workbook1.xlsx"
  4. qryout = "NewTable"
  5. DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel12Xml, qryout, fileName, True ', "B2:J32"
  6. End Sub
The first time ran without a hitch (first time I've done this :) ) Notice I set the qryout="newtable"... when ran, this table was created and then populated with the correct information. I then opened the workbook and made a few changes and added a few new "records"... I then ran the same code a second time and these changes were appended to the table.
I suspect, then that an update query would be called for and then ether delete the table or clear the records.
An update query would allow the changed data to reflect in the orginal table and any new records should be appended.

You should make a copy of your production database and see if this points you in the right direction.

-z
Attached Images
File Type: jpg TrnsXData.jpg (51.3 KB, 4094 views)
May 15 '12 #4
dchyde
3
Thanks zmbd. This is all over my head, I'm afraid. I am probably in the wrong place for someone of my level of sophistication. You were very generous with your time in putting this together and I am ashamed at not being able to take advantage of your effort. I need to get "Access and Excel for Dummies."
May 15 '12 #5
NeoPa
32,556 Expert Mod 16PB
In short, it's possible, but simplifying it for the users would involve a level of automation that I doubt you'd be comfortable with.

Essentially, for any individual worksheet, the process would have to include :
  1. Import the raw data in. Probably into a temporary table.
  2. Using this table update the original data in such a way that records from the temporary table and records from the original database are matched accurately and reliably. Complexity increases related to how many separate fields and possible updates are supported.
  3. If new records are required as well as updates then, as long as they are correctly and safely identified, these can also be handled in the previous step.
  4. Lose the temporary data/table.
May 16 '12 #6
zmbd
5,501 Expert Mod 4TB
@dchyde:

My pleasure...

IN #6, NeoPa stated the steps in a much better way than I did in my post.

As for being in over your head... better to drown than to have the lions eat you for lack of trying! };-) Even the "Experts (which I am not!) started out in the shallow-end of the pool!

- Because we don't have all of the design information behind your database, any further suggestions that I might make might muddle things further for you. However, I can see this working in my mind's eye!

Best Wishes
-z
May 16 '12 #7
nico5038
3,080 Expert 2GB
@dchyde,

You're right about your statements in #3. The number of changes will be limited and manual updates are in my eyes to be preferred, as the coordinators can make errors too. By automating this process you loose a set of eyes checking for errors and the time to build this is probably more than the time needed to make the changes manually.
The best way would be to switch in the future to a web based application and authorize the coordinators to maintain the name and address data.

Nic;o)
May 17 '12 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: Jeff | last post by:
I will start off by giving you a background of the process I am taking. The nature of my DTS package is that I recieve an Excel Spreadsheet, run it through the DTS Package applying validation to...
0
by: (Pete Cresswell) | last post by:
I'm writing a loop that Dir$'s through about a hundred MS Excel spreadsheets and extracts info from maybe 5-20 workbooks within each into a staging table. Problem is that I don't think I have any...
1
by: garry.oxnard | last post by:
Can anyone help me to solve a problem which involves switching from Access to Excel (then back to Access) programatically please? I have an Excel template which, on open, also opens an Access...
3
by: aniphilip | last post by:
Hi All, I have a requirement to automate Access functionality from Excel. I need to open Access, trigger button events and close Access from Excel. I Achieved opening Access from Excel. I...
4
by: somanyusernamesaretakenal | last post by:
What I am trying to achieve: Basically I have generated a report in access. This report needs to be updated using excel. (Updating the new data, not changing existing data) What I did was I...
5
by: billelev | last post by:
Hi there. I need to perform a number of financial calculations within a database I am creating. Rather than writing my own functions, I figured it would be worthwhile to use the functions that...
0
by: DrewYK | last post by:
I have the project that may never end in front of me. I am creating a routine that will take SpreadSheets from Excel and bring them into Access. I am not using any "DoCmd"s because the goal...
3
by: Umoja | last post by:
Hi All, This seems like a simple thing, but I can’t seem to figure it out. I am familiar with transferring excel spreadsheets into access using the TransferSpreasheet function...
3
by: lord lolipop | last post by:
i'm trying to extract data from ms access using excel's vba .. i;m using combo box to select ..like for an example in my combo box there's GSM and PDA .. then when i select GSM then information will...
0
by: SlowNsteady | last post by:
Hi My name is Sri. This is my first question to this forum Forgive me if i posted this question in the wrong forum. I want to export a the picture which is in the doc file to excel sheet. i...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.