473,657 Members | 2,461 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Run Update Query silently in background

I have a MS access 200 DB in which I have an update query which
repalces all the " " with ''" in a field. I would like the update query
to run in the background, and not ask the user for any perrmissions. I
was thinking to run the query as part of the autoexec macro.

can anyone recommend a way that I can have the update query run in the
background? I don't see an obvious way to set the SetWarnings command
for the query.

Any help would be greatly appreciated.

Best wishes,

George
gh********@yaho o.com

Dec 30 '05 #1
4 30004
gh********@yaho o.com wrote:
I have a MS access 200 DB in which I have an update query which
repalces all the " " with ''" in a field. I would like the update
query to run in the background, and not ask the user for any
perrmissions. I was thinking to run the query as part of the autoexec
macro.

can anyone recommend a way that I can have the update query run in the
background? I don't see an obvious way to set the SetWarnings command
for the query.

Any help would be greatly appreciated.

Best wishes,

George
gh********@yaho o.com


CurrentDB.Execu te "QueryName" , dbFailOnError

--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Dec 30 '05 #2
Another way to do it is to use (in VBA):
On Error Resume Next
DoCmd.OpenQuery "qryName"

Dec 30 '05 #3
Steve wrote:
Another way to do it is to use (in VBA):
On Error Resume Next
DoCmd.OpenQuery "qryName"


I don't believe that would eliminate warnings and confirmation prompts.

--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Dec 30 '05 #4
Sorry, I meant:
DoCmd.SetWarnin gs False
DoCmd.OpenQuery "qryName"
DoCmd.SetWarnin gs True

Don't know what I was thinking when I wrote the On Error Resume Next
bit.

Dec 30 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
7030
by: Bill Clark | last post by:
I have about 20,000 records pulled from Excel that I need to update. What I need to do is run an update query that bascially says: If a field is null, update it with the previous record value of that same field. In some instances, it will have to go back a few records before it finds a value that is not null. Can this be done? Thanks Bill
5
13213
by: Don Seckler | last post by:
I have an update query that runs when a report closes. I have several reports that will need to run the update query with diferent criteria. I'd like to simply make the criteria change in the report vba instead of making different queries. Here's my query sql: UPDATE Draw SET Draw.Billed = Yes WHERE (((Draw.Billed)=No) AND ((Draw.WholesalerName)="Hudson"));
10
3261
by: Randy Harris | last post by:
I imported records into a table, later found out that many of them had trailing spaces in one of the fields. If I'd caught it sooner, I could have trimmed the spaces before the import. This wouldn't work (nothing changed): UPDATE tblManuals SET tblManuals.PARTNUM = Trim(); Would someone please tell me how to do an update query that will trim the spaces?
5
4694
by: Andrew | last post by:
I've got a list box that selects a record on a subform, and in that subform are a few text fiels and a button that runs an update query. How do I have the update query button run and only update the record that is selected in the list box? The data updates right, but I can't get the update query to do anything but update all of the records. Thanks, Andrew
4
11327
by: deko | last post by:
I'm trying to update the address record of an existing record in my mdb with values from another existing record in the same table. In pseudo code it might look like this: UPDATE tblAddress SET AddressDescription of Entity 456 = AddressDescription of Entity_ID 123 Address1 of Entity 456 = Address1 of Entity_ID 123 City of Entity 456 = City of Entity_ID 123
7
3527
by: Mark Carlyle via AccessMonster.com | last post by:
I have this update query that I am trying to run. I know the syntax is messed up but do not know how to correct it. Select 'UPDATE', Transactions,'Set = where = ' From "Get Daily Balances" Transactions = name of the table I want to update balance = name of the field i want to update daily balance= name of the query result that I want to move to the table
0
449
by: ghadley_00 | last post by:
Run Update Query in silently in background I have a MS access 200 DB in which I have an update query which repalces all the " " with ''" in a field. I would like the update query to run in the background, and not ask the user for any perrmissions. I was thinking to run the query as part of the autoexec macro. can anyone recommend a way that I can have the update query run in the background? I don't see an obvious way to set the...
2
5063
by: bobabooey2k | last post by:
I have an update query with one field having in its "Update to" cell a DLookup statement. This query takes 2-3 minutes on 3000 records. Can I avoid dlookup here using multiple queries? An underlying subquery to this Update query involves a MAX function on a date field, which is then used in the DLookup statement. Any help appreciated. Thanks Richard
8
1606
by: HenHouse | last post by:
Hi folks; Here's a mystery for you. I've written an update query that runs every time my database opens and does a little housekeeping amongst the records. It updates a yes/no value in one table to True if a text value in another table ="Client". Anyway, I run the query and it gives the usual "You are about to update 83 records blah blah.... Yes or No?" But if I click Yes, nothing happens! The 83 records stay un-updated! Anyone know...
1
3130
by: giovannino | last post by:
Dear all, I did a query which update a sequence number (column NR_SEQUENZA) in a table using a nice code (from Trevor !). 1) Given that I'm not a programmer I can't understand why numbering doesn't start always, running more times the update query, from the same starting parameter assigned (1000000000). It seems to me that it takes memory last number calculated and running prox update it starts from last table row updated. I need...
0
8392
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8305
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8823
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7320
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4151
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4301
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1944
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.