473,382 Members | 1,368 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,382 software developers and data experts.

Permissions problem caused by compact

Hello All

I have a database (Access 2000, running on Win 2000), which suffers from
bloat over a period of time. In order to solve the problem I set the
option to compact on exit. This however has caused a problem. The
permissions of the mdb file which are set to Everyone-Full control, are
reset when the database is compacted. The end result is the the users
get a message saying Access cannot locate the database. I can run it
with Admin rights, but normal users cannot.

It seems that my only option is to not "compact on exit".

Has anyone come accross a solution to this problem.

Any help would be appreciated.

TIA
Trevor

Nov 13 '05 #1
3 2349
Trevor,

I know, these inflating Access databases are a real pain in the ass.
There is no silver bullet solution, but there a few things to think about,

1. Don't store pictures, movies etc. in your databases. This is really no.1
causing bloated databases
2. Split your databases, that is create a data backend and a application
frontend. Install the frontend application on the client machines.
3. Don't change/add/delete database objects like forms and reports too much.

These measures will most likely reduce the need to compact (recreate!)
databases and you might consider to schedule compacting Access databases
using the /compact commandline option.

For instance:
C:\Program Files\Microsoft Office\Office9\MSACCESS.EXE C:\Temp\Test.mdb
/compact

This example will compact the C:\Temp\Test database without even opening it.

Hope this might help you,

Mark Zuijdhoek

"Trevor Hughes" <tr**********@inet.net.nz> schreef in bericht
news:10**************@kyle.snap.net.nz...
Hello All

I have a database (Access 2000, running on Win 2000), which suffers from
bloat over a period of time. In order to solve the problem I set the
option to compact on exit. This however has caused a problem. The
permissions of the mdb file which are set to Everyone-Full control, are
reset when the database is compacted. The end result is the the users
get a message saying Access cannot locate the database. I can run it
with Admin rights, but normal users cannot.

It seems that my only option is to not "compact on exit".

Has anyone come accross a solution to this problem.

Any help would be appreciated.

TIA
Trevor

Nov 13 '05 #2
Trevor Hughes <tr**********@inet.net.nz> wrote:
I have a database (Access 2000, running on Win 2000), which suffers from
bloat over a period of time. In order to solve the problem I set the
option to compact on exit. This however has caused a problem. The
permissions of the mdb file which are set to Everyone-Full control, are
reset when the database is compacted. The end result is the the users
get a message saying Access cannot locate the database. I can run it
with Admin rights, but normal users cannot.


You need to give the users full rights to the directory. Or create a shortcut which
has an admin user on it which will do the compact.

The problem here is that Access compacts to a new file name and, if all goes well,
then deletes the old file and renames the new file to the old file name. Deleting
the old file then loses the permission settings on the old file.

Tony
--
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Nov 13 '05 #3
Trevor Hughes <tr**********@inet.net.nz> wrote in
news:10**************@kyle.snap.net.nz:
I have a database (Access 2000, running on Win 2000), which
suffers from bloat over a period of time. In order to solve the
problem I set the option to compact on exit. This however has
caused a problem. The permissions of the mdb file which are set
to Everyone-Full control, are reset when the database is
compacted. The end result is the the users get a message saying
Access cannot locate the database. I can run it with Admin
rights, but normal users cannot.

It seems that my only option is to not "compact on exit".

Has anyone come accross a solution to this problem.


Users should never be compacting the database. Period.

That's an administrative function because:

1. it could fail, and somebody needs to recover from it.

2. it's not something that should need to be done very often in a
properly designed database.

First off, if you have the data tables and the forms and reports all
in the same MDB file, you've got the wrong architecture for
multi-user setups. That setup can lead to bad bloating, corruption
and weird behavior for end users. The only proper multi-user setup
is to have the tables in a back end MDB on a shared server, and each
user opening a local copy of the forms/reports, etc. (i.e., the
front end) on each workstation.

Second, with a split architecture, you don't really need to compact
the front end. If it's bloating enough to be a problem (either size
or performance), then there's something dreadfully wrong with the
design of your front end.

If you're experiencing lots of bloat, it's probably due to the fact
that you seem to have all your users opening the same MDB. Get rid
of that error and you'll probably no longer have bloat.

Compact on close is a waste of time, and, I would say, dangerous. It
cannot be bypassed and sometimes you want to close Access without
compacting, say if suspect something is corrupted in it. If you
compact, you may lose data that would be otherwise recoverable.

Now, none of this is to say that back end data files don't need to
be compacted occasionally. But it's not something that should need
to be done often, only as a maintenance task. When you do it depends
on how the MDB is used. If it's got lots and lots of additions and
has non-randomly distributed primary key values in most of its
tables (such as AutoNumbers) and there are large numbers of records
(100s of thousands), it might be helpful to compact the back end
once a day (to rewrite the index pages and the data pages, which
will be rewritten in primary key order). This can be an automated
process that is done at night when everyone is out of the office.

If you don't have that kind of heavy appends or tables that large,
you can easily get by with a weekly compact.

Of course, any compact cycle of your precious data file should
include the making of a backup copy *before* the compact.

That's precisely why compact on close is bad, because you don't end
up with a backup.

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 13 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Peter Verhelst | last post by:
Hello, Currently I am running an Access database on a windows WTS server, running Microsoft Windows 2000 server 5.00.2195 Service Pack 3. This database should be accessible for everybody in our...
2
by: Tim Chmielewski | last post by:
I have a an Access 2000 database that I have given read & write permissions to the IUSR & IWAM users on my machine (for a web application), but every time I open the database directly, it loses the...
0
by: Michael J. Bigos | last post by:
Has anyone else come across this? We are building an ASP.Net application that uses a certficate in the local machine store to sign XML data before transmitting it to a third-party. The third...
9
by: jab3 | last post by:
So I'm considering a small project that involves online file storage. Let's say I wanted to set up a site that allows people to log-on, create an account, and then have space to upload files. The...
2
by: rrossney | last post by:
Please look at the "what I've already done" section of this message before responding to it: I believe that I've done everything that the people who experience this error are typically told to do....
3
by: Pachydermitis | last post by:
Hi everyone, This is not the forum for Windows permissions, but I figure this has to be an issue one of you access experts has had to deal with. I have an XP system with an access db on it. The...
8
by: jporter188 | last post by:
Hello, I am working on a project to manipulate XML files. All of the files, the code, and the output are on network drives. When I run my program I get an exception (see below). I tried giving...
1
by: SysProg | last post by:
I need some help with a problem I've encountered. I am a zLinux, WAS, and DB2 noob so please bear with me. I am helping to support two WebSphere applications which utilize DB2 under zLinux. One...
1
by: Jim Mandala | last post by:
I had a user that converted an application from Access 2003 to Access 2007. The application is split front-end/backj end. When trying to open certain forms, the front end reportst that they don't...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
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
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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?

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.