I'm working on a mini-project at work:
I need to Import data from SQL server 2008 to Access 2007 so that an end user can access the data/run reports etc.
Things I am not allowed to do:
I am not allowed to link the data [don't want the end user running queries on the SQL server database which is live]
I am not allowed to create a SQL task/SQL job/SSIS package to do this nor am I allowed to write a little application in C#/VB.NET etc.
Things I can do:
I'm only allowed to create an Access form which copies data from the SQL server database to a local Access DB on a button click.
I must store the connection string in an inaccessible place so that the end user cannot see it/edit it
Things I've tried
I've tried to use the "External Data Import" manually and that works just fine but creates a new table every time I run it [Something like MyTable1, MyTable2].
I can't seem to find any sources that concisely describe how I could automate this [save for the button click].
I would like for someone to point me to resources or help me figure this out. I am not looking for someone to write code for me. I just don't know where to start.
DoCmd.TransferDatabase. Delete the old copy of the table first in order to avoid that naming issue.DoCmd.TransferDatabasework if I need to copy only a subset of tables? Also, how is this different fromDoCmd.TransferSQLDatabaseDoCmd.TransferDatabaseto import it into Access. Repeat that process for each of your other tables.