How do I add a password?

  • Thread starter Thread starter Ed
  • Start date Start date
You don't. You can set up the built-in user-level security and then you can
decide who can and can't run that query (if you save it).

Access is not really designed to pop up password prompts all over the place
(thank goodness) You set up security to determine who can do what, they log
in one time when they open the database, then the security is set for the
whole session.

There are codes that you can write topop up passwords, but they are not very
secure, and very messy. Personally, I would not want to type in a password
everytime I went to do a high-level function.

Rick B
 
Sorry, I was too brief on what I was trying to do.
The table has a password and I went to sent the password with the query!

ed
 
How did you tie a password to a TABLE?


Ed said:
Sorry, I was too brief on what I was trying to do.
The table has a password and I went to sent the password with the query!

ed
 
Sorry again, I use a password to open the database where the table is. I am
in another database and would like to access Table1 using this query.
 
I have two databases. The one I am in and the one that has Table1.

The database that the Table1 is in has a password. When I run the query
from the second database, it gives me an error message "Not a valid
password". I know the password, I just do not know how to add the password
to the SQL.
 
Ed said:
I have two databases. The one I am in and the one that has Table1.

The database that the Table1 is in has a password. When I run the query
from the second database, it gives me an error message "Not a valid
password". I know the password, I just do not know how to add the password
to the SQL.

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

If you're using .mdb files & not .adp files it can be done like this:

SELECT *
FROM table_name IN "c:\temp\myDB.mdb;PWD=mypassword"
WHERE <criteria>

Microsoft recommends that you link the external table to the local file
and just query on the linked table rather than use the IN predicate.
When you link the table you will be prompted for the password. After
the link is accomplished, you don't have to enter the password to access
data from that table.

--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQhpJ94echKqOuFEgEQJQ9ACgpSXuiwAj7jIhy5toOI5FZQE+xMkAni3V
+HFtSvvAVip2yaXQC9xJJxCu
=uc8Z
-----END PGP SIGNATURE-----
 
Did not work. I put in:

SELECT *
FROM Table1 IN 'c:\DR_be.mdb;PWD=dirt';

I put in double quotes and Access changed it to single quotes. I get a error
message that says 'Could not find file 'c:\DR_be.mdb;PWD=dirt'.
 
I can't find any references on how to do this. Why not create a linked table
instead?
 
SELECT *
FROM Table1
IN '' [MS Access;PWD=dirt;DATABASE=C:\DR_be.mdb];

That's 2 single quotes after IN

Gary Walter
 
Thanks, that worked great!
ed

Gary Walter said:
SELECT *
FROM Table1
IN '' [MS Access;PWD=dirt;DATABASE=C:\DR_be.mdb];

That's 2 single quotes after IN

Gary Walter

Ed said:
Did not work. I put in:

SELECT *
FROM Table1 IN 'c:\DR_be.mdb;PWD=dirt';

I put in double quotes and Access changed it to single quotes. I get a
error
message that says 'Could not find file 'c:\DR_be.mdb;PWD=dirt'.
 
Back
Top