A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

"In" Query Question



 
 
Thread Tools Display Modes
  #1  
Old March 11th, 2007, 09:24 PM posted to microsoft.public.access.queries
[email protected]
external usenet poster
 
Posts: 3
Default "In" Query Question

I am trying to use the below query to access another Access database
that is password protected. When I run the query as-is it says the
passowrd is invalid. How can I incorporate the password into the
below query?? Thanks in advance.

INSERT INTO Titles (Title, Comments) IN 'C:\Documents and Settings
\db1.mdb'
SELECT Titles.Title, Titles.Comments FROM Titles;

  #2  
Old March 11th, 2007, 11:28 PM posted to microsoft.public.access.queries
'69 Camaro
external usenet poster
 
Posts: 1,049
Default "In" Query Question

Hi.

How can I incorporate the password into the
below query??


Try:

INSERT INTO [;DATABASE=C:\Documents and Settings\db1.mdb;PWD=myPswd].Titles
SELECT Titles.Title, Titles.Comments FROM Titles;

HTH.
Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips and tutorials.
Blogs: http://DataDevilDog.BlogSpot.com
http://www.Access.QBuilt.com/html/ex...ributors2.html for contact
info.


wrote in message
oups.com...
I am trying to use the below query to access another Access database
that is password protected. When I run the query as-is it says the
passowrd is invalid. How can I incorporate the password into the
below query?? Thanks in advance.

INSERT INTO Titles (Title, Comments) IN 'C:\Documents and Settings
\db1.mdb'
SELECT Titles.Title, Titles.Comments FROM Titles;



  #3  
Old March 12th, 2007, 11:54 AM posted to microsoft.public.access.queries
Gary Walter
external usenet poster
 
Posts: 613
Default "In" Query Question


SSweez wrote:
I am trying to use the below query to access another Access database
that is password protected. When I run the query as-is it says the
passowrd is invalid. How can I incorporate the password into the
below query?? Thanks in advance.

INSERT INTO Titles (Title, Comments) IN 'C:\Documents and Settings
\db1.mdb'
SELECT Titles.Title, Titles.Comments FROM Titles;


In addition to Gunny's sage help...

INSERT INTO Titles (Title, Comments)
IN '' [MS Access;PWD=fred;DATABASE=C:\Documents and Settings\db1.mdb]
SELECT T.Title, T.Comments FROM Titles AS T;

that's 2 single quotes before "["

change "fred" to your actual password


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:14 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.