Solved

Temporary table solution for web db

Posted on 2011-09-08
4
370 Views
Last Modified: 2012-05-12
I have created a hybrid Access application, but have the need for a temporary (local) table to exist in each users copy. This table will be used to allow each user to play some "what if" scenarios. By "hybrid Access application", I am talking about an Access application that has been published to SharePoint, but each user runs an Access file locally with the data being stored on SharePoint. This works very nicely allowing users to use native forms instead of dealing with the browser limitations.

Thanks, Dale
0
Comment
Question by:dlogan7
  • 2
4 Comments
 
LVL 84

Accepted Solution

by:
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 250 total points
ID: 36501848
Just add the table to the Access app, and don't publish that to Sharepoint. Or, create the table when the app is opened, and delete it when it's closed.

Here's a good collection of Access DDL functions:
http://allenbrowne.com/func-DDL.html
0
 
LVL 57
ID: 36502036
 Other option is to create a temp DB, create the table in there (number of ways to do that), then kill off the temp DB when your done.

Jim.
0
 

Author Comment

by:dlogan7
ID: 36520007
LSM,

I checked out the solutions at the link you provided. My first thought was that there was no way I could pull that off. I am very weak when it comes to VBA. I attempted the one named: CreateTableDDL. When I ran it i get a user-defined ...error on the very first line:

Dim cmd As New ADODB.Command

Also, I don't think you can NOT publish something to SharePoint. When you sync, it gets everything.

Jim,

<create a temp DB, create the table in there >
Again, that may be over my head. Most of my users for this project are using Acces Runtime and don't have the full version of Access. Would your suggestion be possible then?

Thanks, Dale


 
0
 
LVL 57

Assisted Solution

by:Jim Dettman (Microsoft MVP/ EE MVE)
Jim Dettman (Microsoft MVP/ EE MVE) earned 250 total points
ID: 36522483
Dale,

<<<create a temp DB, create the table in there >
Again, that may be over my head. Most of my users for this project are using Acces Runtime and don't have the full version of Access. Would your suggestion be possible then?>>

  Yes.  Here's an example of some VBA that creates a temp DB:

430       pb.SetMessage "Creating scratch database..."

          ' Set the temp database location\name
440       gstrTempDatabaseName = "C:\TravUtilsGLImport.MDB"

          ' Kill the temp database if it exists
450       On Error Resume Next
460       Kill gstrTempDatabaseName
470       On Error GoTo btnVerify_Error

          ' Create temp database
480       Set dbsNew = DBEngine.Workspaces(0).CreateDatabase(gstrTempDatabaseName, dbLangGeneral)

          ' Create table for transactions
490       DoCmd.TransferDatabase acExport, "Microsoft Access", gstrTempDatabaseName, acTable, "tblGLImportData_Template", "tblGLImportData", True

          ' Create errors table
500       DoCmd.TransferDatabase acExport, "Microsoft Access", gstrTempDatabaseName, acTable, "tblGLImportErrors_Template", "tblGLImportErrors", True


It's very stright forward.  Although what LSM suggested would work very well, especially if you added the compact on close option, which would reduce the size of the FE by reclaiming the deleted temp table space.

Jim.
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It took me quite some time to sort out all the different properties of combo and list boxes available from Visual Basic at run-time. Not that the documentation is lacking: the help pages are quite thorough and well written. The problem was rather wh…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

895 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now