I created a MS Access 2000 database and its tables while logged in as "Jane." But all the tables in are owned by "Admin. " When I display CurrentUser() it is "Admin," no matter how I am logged in or on what computer. But there is no Admin account on my computer. What's going on here? How can I determine who creates which tables and queries in this database when they all end up being owned by "Admin"? How can I use permissions if everyone is Admin?
Current user?
Collapse
X
-
Windows User accounts/permissions and Access have no relation.
If you need to set up your Access database to have multiple user permissions, it needs to be done manually.
Regards,
Scott -
After you've done what Scott has suggested, you can click on Tools ==> Security ==> User and Group Permissions ==> Current Owner Tab, to view the current Owners for every Object in your Database and change it if you have Administrative privileges. BTW, assigning Database Permissions in a Database is not for the faint of heart. Do not just jump in, research, use the User-Level Security Wizard as a start, backup your System.mdw file, and pray!Originally posted by jzfrazerI created a MS Access 2000 database and its tables while logged in as "Jane." But all the tables in are owned by "Admin. " When I display CurrentUser() it is "Admin," no matter how I am logged in or on what computer. But there is no Admin account on my computer. What's going on here? How can I determine who creates which tables and queries in this database when they all end up being owned by "Admin"? How can I use permissions if everyone is Admin?Comment
-
Be aware that no truer words than the above have ever been written on this or any forum!Originally posted by ADezii...assigning Database Permissions in a Database is not for the faint of heart
One of your statements is kind of scary, too!
How many people are you allowing to create tables and queries in this database? Allowing users direct access to tables is really bad practise!Originally posted by jzfrazerHow can I determine who creates which tables and queries in this database
BTW, in case you have any use for it, Environ("userna me") will give you "Jane" when you’re logged into Windows under that name.
Welcome to TheScripts!
Linq ;0)>
Comment
-
Thank you all for your advice. Missinglinq, your tip about Environ("Userna me") solved one of my big problems, and I am extremely grateful.
Since I worked with relational databases for 20 years, including a stint as a principal consultant with Ingres, I'm not a total ignoramous nor faint of heart. But I must admit some features of Access have me baffled. I did try using the security wizard, but all that happened was that I was unable to access the database again. Lucky I had a backup.
I still can't figure out who this "Admin" is. Do I need to use Tools ==> Security ==> User and Group Permissions and manually change the owner of every object to "Jane"? Then how will it know that I am "Jane" when I log in?Comment
-
I thought I had posted an article about Access Security but I can't find it. First of all, forget the security wizard, it sucks. The best source is a book called the Access Developers Handbook by Litwin and Getz that explains Access Security very well.
A full description of Access security would take pages but I will try to give an outline.
Ok, haveing written masses and realising it don't make sense and deleted it, go buy or borrow that book, it really does help you understand the Access Security system, which is amazingly powerfull, albeit very complex.
Admin is the default user of any Access database. In System.mdw and all newly created mdw, Admin has no password and so you never see the login screen. You need to create a new mdw, set a password for Admin, then you will be forced to log in and you can create new users and groups, assign permissions (and more importantly, revoke permisions from Admin and User).Comment
-
It sounds like your best bet is simply to ignore the security side of Access. In most setups Admin == Everyone.
The idea is that the security system defaults to full unrestricted access (small a) to all users. Using it to restrict this access automatically puts you in a position that involves lots of manual manipulating of permissions.
Someone said it could be powerful. It certainly is, but it's a long way from being administrator friendly.Comment
-
-
Thanks, Lysander, for explaining this all to me. You solved a prolem I have been gnashing my teeth overfor a week, and I have now been able to do what I wanted to do. It seems that user and group permissions work the same way as in any other SQL based DBMS as long as you know about this "Admin" default user and how to get the current user recognized as the current user. Too bad MS help is so abysmal.Comment
Comment