Topics Search

Running of Update Queries when I open the Database

Running of Update Queries when I open the Database
Views: 39
I need to be able to run an Update Query when the database is opened. I have the AutoExec macro already but the rest is what I need to figure out
Sponsored Links:

Similar posts...


Running an update query

Running an update query Icon
It seems there are many ways to skin a cat running SQL in VB. Here's my very basic question.

I have two update queries in my Access database. Query_Update_Avail and Query_Update_NotAvail. The queries simply set the value in a field to Yes or No indicating the line item is available or not. The queries work fine.

I have a checkbox on my form that when checked I would like to execute the Query_Update_Avail. When unchecked it would execute the Query_Update_NotAvail query. Both suppressing any warnings regarding "you are about to update X records"

I'm sure this is simple but I just need the syntax

Running Multiple Queries Simultaneously?

Running Multiple Queries Simultaneously? Icon
I need help with running multiple queries that are in relation to each other to perform one function, in addition to that, being able to use one parameter in those queries performing one function.

ATM I have to click each query and input the same parameter 2-3 times. It is quite painstaking to do. Everything in my database is functional, I just couldn't find a way to shortenit.

One function has different types of queries: Update, Append, and Delete.

running multiple update queries with one command, query, etc

running multiple update queries with one command, query, etc Icon
people. I need urgent help.
I have many update queries in access 2003. I have to run all the times and I would to create SQL, VBA or combination of both to create a process where I can do this by just one query, button, function etc. I can't do this in a macro because the list of these update queries can increase or decrease at anytime and then I would have to update the macro. It defeats the purpose. All of these queries start with common name "0010 01."

I want something where it says look up queries if it starts with 0070 01 then Run it.
Using this following SQL

FROM MSysObjects
WHERE Name Like "0010 01*";

I can come up with the list of queries but I am not sure how utilize this into VBA or anywhere else to automate the process to meet my requirements.
Like I said earlier I want something where it says look up queries if it starts with 0070 01 then Run it. I am open to other options if you have any

Open form with subform No Update

Open form with subform No Update Icon
I have built a form, with a field called ID and four subforms, each on its own page, each of which display a query based on ID. As it is now, when I open the form, it runs the 4 queries with the empty field, then when I update the ID field in the main form, all 4 queries run.
What I want is 1) to open the form with no queries running, giving chance to insert an ID in the main form
2) for each query to run only when its page is selected

Database/Queries Running Very Slow?

Database/Queries Running Very Slow? Icon
I am making an Ms-Access database for Real Estate Management? I have succeeded in doing all that which is enlisted below, the problem is that the database is running very slow? I don't know what can I do now? The queries is running very slow thatmakes me to wait too much, I want to make the database run very fast?

Creating Action Queries - Update, Append and Delete Queries

Creating Action Queries - Update, Append and Delete Queries Icon
Most Microsoft Access database users will use database queries to request or question information from one or more of your database tables. In Microsoft Access certain queries can also be used to change data as well as display or retrieve it.
These queries, defined as Microsoft Action queries, will allow the user to update data (Update Query), delete data (Delete Query) or add data from one database table to another (Append Query).

Sharing an Access DB with multiple users

Sharing an Access DB with multiple users Icon
I created an access database for the sole purpose of sharing approved data with my entire company. The end users will view the data in a Form which utilizes several tabs and also gives them the ability to run pre-set queries out of the Form.

The Form was created using several queries which were built from tables off of the server. The tables update every day,

The problem I am running into is that it takes about 2 minutes to open the DB (the DB opens directly to the form and all queries run immediately to update), which is annoying to end users and might deter them from actually using the tool.

I have tried moving the DB to SharePoint, but that did not work due to the size of many of the tables.

Storing Information From Queries?

Storing Information From Queries? Icon
I'm working with a 1gb database and have about 20 queries that analyze and summarize the database in different ways. I tried running a separate query that runs all 20 of these queries, but it's just too much for my computer.

Is there a way to, maybe, write a macro that runs each query individually, and stores the result from each query? Any ideas on how to automate the running of these queries, and store the results?

Database Size?

Database Size? Icon
I run a MS Access database monthly and I have been facing different issues every month. Here is some information about the database:
Source information loaded in my database comes from a text file (550 MB, 670,000 rows & 100 columns) extracted from Peoplesoft. There are 38 tables:

One table that stores all data. (670,000 records and 150 columns)
And additional 34 tables used to map data. The biggest ones have 74,000, 7,000, and 11,000.
There are 70 queries and 30 queries are Update queries that update the main table that contains all records.
This same database has 2 recorded macros. One of them runs all 26 update queries.

The columns have no primary key or indexes or an identifier that makes the record unique.
I also need to constantly compact and repair it.

1) The macro takes 1:30 hours to run 26 update queries alone. It takes too long!
2) After this macro runs, some of the queries are successful and some are not but no error message is generated...

How to run macro from another database?

How to run macro from another database? Icon
I've desinged two database one for queries and another for report ( coz data was too big). I'm trying to open only report dbase, because most of the data from queries database after running all queries from the queries dbase.What I have done was trying to open only 1 dbase (report) run queries at the queries dbase. followling VB code I have tired.

Dim AppAccess As Object
' Create instance of Access Application object.
Set AppAccess = CreateObject("Access.Application")
'Open Service Desk KPI Metrics Queries.mdb database in Microsoft Access window.
AppAcsess.OpenCurrentDatabase "C:\Documents and Settings\ricop.dongol\My Documents\Service Desk KPI Metrics Queries.mdb", False
'False so as not to open in exclusive mode
AppAccess.Run "KPI1"

Set AppAccess = Nothing

MsgBox "Done!"

after run command I received error msg object required?