RE: Setting up queries to run on a schedule



I found a few articles:
http://www.orafaq.com/faqodbc.htm#ACCESSATTCH
http://www.mvps.org/access/tables/tbl0010.htm

Barry

"Frank" wrote:

would there be a command that would allow me to establish the connection
before I open a query?

"Barry Gilbert" wrote:

I'm not sure about Oracle, but you should be able to save the password in
your odbc connection.

Barry

"Frank" wrote:

Thank you Barry!

This will work for me. However, I have on obstacle I have not found a
solution for. I am connecting to an Oracle Database with an ODBC. I need to
enter a password in order to make a connection. I have not found a command
in the query builder that lets me do this. Is there one? If not is there a
way for me to enter it?

"Barry Gilbert" wrote:

The way I do this is to create a macro for each job I want to run. In your
case, each macro would run a single query. The macro would have two lines:
OpenQuery
Quit
There is a command line switch that allows you to run a macro when the mdb
opens. You use it like this:
c:\myDatabase.mdb /x myMacroName
In some cases (not sure why), you need to specify the path to Access in
front of your mdb:
c:\Program Files\Microsoft Office\Office\msaccess.exe c:\myDatabase.mdb /x
myMacroName

I find it easiest to put this string into a batch file so I can test it
before setting up the scheduler.

Then, on a server or a PC that's always on, create a scheduled task using
the Windows Task Scheduler. The task runs the batch file.

Don't forget to put the Quit statement in your macro so it exits Access when
done.

Barry

"Frank" wrote:

I have some queries that need to run on a regular basis to capture some
operating data. Right now someone logs in and executes the queries on an
hourly basis. Is there a way for me to set them up so they run automatically?
.



Relevant Pages

  • Re: Unwanted dialog when performing a mail merge
    ... the template and stops executing code; code in an AutoNew macro in the Word ... "ODSO expects an SQL query for the data source in the SQLStatement argument ... missing information" made me insert the Connection argument again, ...
    (microsoft.public.word.vba.general)
  • RE: run-time error 1004
    ... check box from the "Cancel the connection if not connected within" in the MS ... Is there another place that I change the timeout time? ... Your query may be taking too long to run and get hit with the time ... ' NPB_Macro Macro ...
    (microsoft.public.access.queries)
  • Filling combobox from query
    ... how can i fill a combobox by vba from a query?? ... i have a query in a macro that goes like: ... Connection = Array(Array(_ ... and i want to fill the combobox from teh result of this query.... ...
    (microsoft.public.excel)
  • Re: ASP - FROM statement slows down connection to database
    ... Open your database in Access, switch to the Queries tab, create a new query ... in Design View without choosing a table, swtich to SQL View, paste the sql ... connection string rather than using an ... recordset open statements. ...
    (microsoft.public.inetserver.asp.db)
  • Re: Update checking
    ... My thought was to use a simple query with a "username" param ... concurrency exceptions happen if the data you queried has ... > was and basically let the user work in a similar offline mode. ... Where does connection pooling come ...
    (microsoft.public.dotnet.framework.adonet)