Update Fields In Multiple Tables

Jun 27, 2005

I am trying to setup a database for vehicle stock control.
Im not sure if I have gone about this the right way as I am new to this but thus far it is working correctly except for one annoying problem.
The database consists of so far

tblIAWVehicleDetails (Primary key "IAWvehicleID" autonumber)
tblIAWSellers (Primary key autonumber)
tblIAWBuyers (Primary key autonumber)
tblIAWStates (Primary key autonumber)
tblIAWStatus (Primary key autonumber)
tblIAWSafetyDetails (Primary key autonumber)
tblIAWSold (Primary key autonumber)

In the Vehicle Details table a stock number has to be manually added as this will be used for new stock as well as current stock (Number range from 100 - whatever) "IAWVehicleNo".
This table contains all relevent data with reguards to make, model, bodytype, color etc.
The sellers table contains the details of the seller Name, address, Phone, LicenceNo etc.
The Buyers table contains employee names.
The States table contains all Australian states.
The Status table contains current vehicle status Retail, Wholesale, Wrecking etc.
The Sold table contains the details of the person who purchased the vehicle if sold.
The Safety details table contains a safety checklist for pre purchase inspections eg: Headlights yes/no checkbox, Headlight text field for any extra info.
It also has a field for a safety Certificate No once the vehicle is checked and recieves a Safety cert.
The forms are setup as
frmIAWVehicleDetails
frmIAWSellers Subform
frmIAWVehicleSafetyDetails
frmIAWVehicleSafetyDetails Subform

The Vehicle Details,Sellers,Sold & SafetyDetails tables all have the IAWVehicleID & IAWVehicleNo Fields but when the details are entered through the forms the IAWVehicleNo which is the manually entered number only updates to the tblIAWVehiclesDetails but the other IAWVehicleNo fields in the other tables remain blank.
Any advice or help would be greatly appreciated.

View Replies


ADVERTISEMENT

Tables :: Update Single Field From Multiple Fields

Nov 6, 2014

I wrote a database several years ago and recently pulled it out to give to a friend. The problem is, back then (not knowing better) I set the Employee table up with as a single field "NAME". Now, in order to make it effective, I need the Employee's name in four (4) parts (First, Middle, Last, Suffix).

I have several queries based on the "NAME" field and and would like to avoid changing all of them. I have a simple form "frmUpdateEmployees" that populates the Employee table and Name field. I was hoping to change the form and/or add a query that would be easier and more simple.

Table: Employee
Field: Name
Form: frmUpdateEmployees
Queries: 16 that depend on the table and field above.

View 5 Replies View Related

Forms :: Inventory - Allow Users To Update Multiple Fields For Multiple Assets

Sep 25, 2014

I want to create a form that allows users to update multiple fields for multiple assets. Below is what I came up with:

Ideally, I'd like the subform to be filled in by having the user select multiple Assets from the S/N combobox field which would then auto-populate the "Type" field. Then they would fill out the appropriate fields they want edited in the top part of the form. They hit save and magic happens. This would also be nice because only assets they want edited would be displayed (easier on the eyes) and no distinguishing would be necessary. To do it this way, I know I would need to use a temp table but I wanna avoid using temp tables.

I know I can do this by adding a Yes/No field in the "Asset" table, setting the "Asset" table as the subform's recordsource, and then putting a checkbox in the subform and allowing them to check the assets that they want to edit (which would also allow me to sort it instantly so that checked Assets are at the top of the datasheet for easy viewing), but I would like to know if there's a way of accomplishing this without the use of checkboxes.

I know I could also use a listbox and that allows them to multi-select items, but I'm not sure if that allows me to group all selected items at the top of the listbox for easy viewing of selected items. Plus it would involve a lot of scrolling (there are over 2k assets).

View 2 Replies View Related

Modules & VBA :: SQL - Select Multiple Fields From Multiple Unrelated Tables

Oct 28, 2013

A small issue I was wondering of for a few day . Is it possible in SQL query to SELECT multiple fields from multiple tables ? Example for the question is

Code:

dim my_var as String
my_var = "SELECT Emp_FName , Emp_LName , Emp_Adress " _
& " FROM Table1 " _
& " AND Emp_Date_Of_Payment , Emp_Sum_Of_Payment " _
& "FROM Table2 " _
& " WHERE Emp_ID = 3 "

Is this code actually valid in SQL gramatics , and is it usable if passed to a Recordset variable ( rs = CurrentDB.OpenRecordset(my_var) ) ? Just FYI - The two tables are not related and I want to keep them that way (If possible relate their records just via SQL/Vba )

View 7 Replies View Related

Multiple Fields Of Multiple Tables To One Table Query Or Report

Apr 12, 2013

I have 10 tables, 30+ fields on each table (every table has the same 'account number' field). I only need from 5 - 20 fields from each table. How do I get the certain fields from each table and put them in a table, query or report?

View 1 Replies View Related

Update Multiple Fields At Once

Sep 6, 2007

Hey guys-
I have 2 identical tables. I want to update the data from Table1 to go into Table2. Each table has well over 70+ fields in them. Instead of handwriting out each [Table].[Field] in either SQL or the Designer- is there a shortcut to tell Access to grab all the fields from Table1 and update all the fields in Table2 (all the fields have the same name)? I just don't have the energy to type it all out- I figure there's got to be a way...

I know when you do an APPEND query in the designer- it will do this for you- but not the UPDATE query...
Thanks!

View 6 Replies View Related

Tables :: Updating Fields In Multiple Tables Without Onclick Event

Oct 23, 2013

I am working on a database which has two tables used as part of a registration and login process.

I would like a couple of fields from table one to automatically update in table two, once the fields in table one are populated without using an 'on click' event.

The reason I would prefer not to use an onclick is because the completion of the form used to generate the users table does not require any buttons for the data to save.

View 1 Replies View Related

Update Query-multiple Fields,1 With Data, 1 Without

Apr 10, 2008

Access2007- Building a query to handle future input...

I run an update query that does what it is supposed to do and gives the proper values.

THEN I add a one more field to the source with the builder using + that has no data in it yet, the query fails and gives blanks, even though one of the fields in the source has data in it.

I would think that the "no data" field would be considered 0.00 value and be added together to the field that has values giving at least the value of the field with values as a result of the query.

Is there a setting somewhere that I need to change so that the no value and the value would be combined? I am using the builder to combine the values in the query.

Thanks.

View 2 Replies View Related

Update One Field Using Criteria From Multiple Fields

Apr 4, 2013

I am designing an update query for a specific field in my table

There are 3 fields: PROVIDER_GROUP, MEDI_CAL_IND, MEMBER_LOW_CAT

I want to update the value of "Y" in the MEDI_CAL_IND field to "N" if:

the medi_cal_ind value is "Y" AND the PROVIDER_GROUP is "Medicare_Part_D"

OR

the medi-cal_ind value is "Y" AND the MEMBER_LOW_CAT is "Commercial"

A screenshot of the table is attached.

View 5 Replies View Related

I'm Sure This Is Very Easy: Update Multiple Fields Based On One Field...

Jul 26, 2006

I promise I have searched, but I hav spent 10 minutes reading through posts that are unrelated...

What is the code to have multiple fields updaterd based on what is input into a field?

---
Example:

A ZIP Code Field, which updates City & State on the form when entered. (I have a table that has over 39,000 ZIPs w/ City & State already there)
---



I have several applications for this, but if someone could explain this use to me, I will be able to figure it out.

Thanks a million!!!

View 1 Replies View Related

Queries :: Update Fields Of One Table With Multiple Criteria

Aug 12, 2015

How can i update fields of one table with update query where creteria are more than one 1

Example:

DoCmd.RunSQL "UPDATE Salary2009toUpdate SET " & Me.Combo2 & "='" & Me.Text4 & "'
Where Empid='" & Me.Combo0 & "'" and where bank='" & Bankname & "'"

What is the syntax error ...

View 5 Replies View Related

Database Update Of Multiple Fields Based In Lookup

Oct 28, 2014

I have two tables, one table (1) hold three fields, one of those fields is the master key (index). The other table (2) has a field which I want to lookup from table 1, that part is working. In the combo box I get all three fields displayed as I make my selection. I want to copy the other two fields as text at the time the lookup index is selected. I do not what the fields to automatically update each time the table is displayed. I have looked at update macros, I've looked at VBA.

View 1 Replies View Related

Update Multiple Tables In One Go

Dec 6, 2011

I need to update data in an Access database(ADO,VBA).

In the Access database, there are three tables as following:

Unit(ID,UName,TID,AID)
Type(TID,TName)
Area(AID,AName)

When a unit has changed its type or area, then the db needs to be updated. My question is how to do it. Can I get a recordset by joining three table, and do the update in one go?

View 8 Replies View Related

Tables :: Using Fields To Update Others?

Jan 9, 2013

I want to update fields B and C in a table based upon another field (A) in the same table but I want:Field B to update when the original field A is changed in the table (I have managed to get this working in the form but I am trying to get the fields in the table to do the same as sometimes we batch update via the tables and this doesn't seem to work so we have to go into each record individually in form view to update the fields) Field C to only use part of the original field. where to start on this?

View 9 Replies View Related

Update Query Is Updating Multiple Fields With Duplicate Data

Nov 1, 2012

I'm running an update query that's based on a select query (that runs some calculations). The update query is updating ALL the rows that should be updated with the information in the select query with data from the final row in the select query, and not on a per ID basis as I think I have it set-up to do. The data looks correct in the update query, but again it's not coming out right.

Here's the SQL for what I've written so far:

UPDATE [Customer_Data Query], Customer_Data INNER JOIN Baseline ON Customer_Data.ID = Baseline.ID SET Baseline.[Unit Hours] = [Customer_Data]![Dur_Days]*[Customer_Data]![Dur_Hours]*[Customer_Data]![Number_Units], Baseline.Availability = [Customer_Data]![Perceived_Avail], Baseline.[Hours Available] = [Customer_Data]![Dur_Days]*[Customer_Data]![Dur_Hours]*[Customer_Data]![Number_Units]*[Customer_Data]![Perceived_Avail],
[Code] ....

I've also tried to force the update to the proper row by adding a criteria based on ID.

Select query, here it is:

SELECT Customer_Data.ID, Customer_Data.Data_Set_Version, Customer_Data.Number_Units, Customer_Data.Perceived_Avail, Customer_Data.MTTR_MTBF, Customer_Data.MT_TR_OR_BF_Hours, Customer_Data.Utilization, Customer_Data.Percent_Scheduled, Customer_Data.Sched_Percent_of_PM, Customer_Data.Sched_PM_Duration, Customer_Data.Sched_CBM_Duration, Customer_Data.Sched_CBM_From_PM, Customer_Data.React_Detect, Customer_Data.React_Rework, Customer_Data.React_False_Alarms,

[Code] ....

View 3 Replies View Related

Update Multiple Forms/tables

Apr 7, 2006

I would like to create a text box where I can input todays date, then I want to be able to select the tables I want to update with that information.
So if I input todays date I can then update my Stock, Sales and Control tables with todays date. Tomorrow I would only like to update the Control and Tape tables with it as its the weekend.
I been playing around with 'new date for next record' scenario but the problem is that on the weekend we would not input any data into some of the tables.
Hope I've explained myself clear enough.

Thanks

Tim

View 3 Replies View Related

Update Values In Multiple Tables

Oct 26, 2005

I am developing an access db where employees are allowed to load tools from a tool store.

I have three tables: tblEmployee, tblTool, tblOnLoan.

tblTool includes a field "QtyOnHand" which is the quantity of a particular tool in store available to be loaned.

tblOnLoan is used to record which employee has what tools on loan.

When an employee loans a tool i need to be able to reduce the QtyOnHand of the tool and record the loan details in tblOnLoan.

When the employee returns the tool i need to increas the QtyOnHand of the tool and record the return against the original loan in tblOnLoan.

i have not yet been able to work out how to reduce or increase the QtyOnHand as tools are loaned or returned.

Can anyone please help?

View 1 Replies View Related

Update Two Different Tables (fields) From One Text Box

Feb 9, 2006

Hi All,

How do update two different tables (fields) from one text box from a form?

Thanks

View 2 Replies View Related

Update Query Covering Multiple Tables

Jan 25, 2006

Hello everyone! I am constantly have to change a field, called Product_Code, that resides on multiple tables. To change the field I have to run a series of 9 update queries. I'm looking for a way for all these updates to occur at the press of one button on a form. So I would set my criteria using fields on the form that correspond to the appropriate fields on the query and when I press the button all the updates would occur. My question is what is the best way to go about programming this form and is a form my best option to accomplish my goal. I hope I have explained this thoroughly enough...if not I am more than willing to answer any and all questions in order to get this task automated. Thanks everyone.

View 3 Replies View Related

Update Form Based On Multiple Tables

Feb 9, 2006

My db has several tables tb1, tb2 tb3 tb4 ..... I have link tb1 to tb2 (tb1Id to tb2)and linked tb2 to tb3 and tb4 (tb2Id to tb3 and tb4)
I have created a form with several field from tb1 and tb2 and a single field for tb3 and tb4. All of the fields except one for tb1 are use to make a decision based on what they display. The only field that is updated on the form is a date conversion field from tb1. once you update this field it will auto populate a date field on tb1 with current date. you then have a choice of 4 commands to activate based on what is displayed form the rest of the form.

my problem none of the fields can be updated. can any one help

qry the form is based on

tb1 [Name]
tb1 [ID]
tb1 [date conversion] 'this is the only field that is manualy updated
tb1 [date] 'updated base on date conversion field being updated
tb2 [field]
tb3 [Yes/no]
tb4 [yes/no]

based on what is displayed on the form you have 4 choices of cmd buttons.

View 1 Replies View Related

General :: Add And Update Multiple Records To Different Tables

Jan 12, 2013

I have a pretty normalized Access Database. The table that I am trying to add new records is tbl_returns and has 4 fields: return_ID, serial, reason and inv_num.

When I sell a card (or a range of the cards) an invoice including all the information is saved as a record in a new row in tbl_invoices.

If a vendor wanted to return a card (or a range of the cards) in the next visit (weeks or months later) I will accept and in most cases they want me to switch the cards with new ones. Therefore in a new invoice (different date and invoice number) I will give him new cards and return the cards that he wanted to change or return.

Now I have to assign NULL to the inv_ID field in tbl_allPins in order to make it available for sell in future. At the same time I want to have a record of the returned cards including serial number , the reasoning of return, invoice number and/or a little note about each one/range of the card(s).These are to be recorded in tbl_returns as you can see.

For instance you want to return serial numbers between 9876 and 9880 (includes 5 cards) because of the "scratch off problems" and your invoice number is 22222, using frm_returns. After you process it and then open the tbl_returns to check the result, you will see 6 records are added instead of 5. I was able to understand why it is happening (I believe so!) but I could not fix it. Also I cold not write a VBA to remove the inv_ID in front of the related serial numbers in tbl_allPins.

Also in another trial was ended up to creating the Form1. Form1 looks better (has no extra records) but I have trouble to navigate through the records in tbl_returns. There was a sub-form added but it was showing all the records in tbl_returns which is unwanted.

By the way, serial numbers and PIN numbers are each a unique number in tbl_allPins.

View 3 Replies View Related

Queries :: Update Command Multiple Tables Using IIF

Aug 10, 2013

I am writing a sql to assign students to each section of a course. The first student would be in the first section and the second student in the second section.

The ClassParam table gives the number of sections for the course and the last period that was assigned.

The Classes table gives the class key number by class name and section number.

The student has the name of class they want to take and I want to move the class section number into the Choice1 field.

The IIF statement seems to work but all of the students are getting the 1st session of the class put into the choice1 field.

UPDATE Students, ClassParam, Classes SET Students.Choice1 = Classes.ClassID,
ClassParam.PeriodAssigned = IIf([ClassParam]![PeriodAssigned]>=[ClassParam]![NumOfSections],1,
[ClassParam]![PeriodAssigned]+1)
WHERE ((([Students]![FirstChoice])=[Classes].[ClassName] And ([Students]![FirstChoice]) Is Not Null And ([Students]![FirstChoice])<>"") AND (([ClassParam]![PeriodAssigned])=[Classes].[SectionNumber]) AND (([Classes]![ClassName])=[ClassParam].[ClassName]) AND ((ClassParam.ClassName)=[Students]![FirstChoice]));

View 2 Replies View Related

Queries :: Update Multiple Tables From One Form

Feb 10, 2014

I have 2 main tables. One with Data that I get from an outside source and cannot be changed. The other is one that needs to be updated as needed. I have a few look up tables so I can identify the codes with the descriptions. In 2003 I was able to make a big query and link my forms to the query to make modifications. I am not able to edit any information in the 2010 query. The people want it to work the way it did in the past but I am not skilled enough in access to do that. Is there an easy way to use a query when updating the form? I used to be able to edit the query itself and it would feed back into the existing tables.

View 1 Replies View Related

Forms :: Create Form To Update Multiple Tables At Once

Jan 9, 2015

I'm working to create a staffing database that houses changes to staffing week over week.

I have one primary table, the "empMaster" table, that stores the employee's name, contact information, etc. I have other individual tables for noting which employee reports to which manager, what their business title is, what group they're in, their training history, etc.

Once I've populated the empMaster table with employee information, I want a form that allows me to update each of the other tables IF there as a change. Some weeks will have a manager change, some only a business title change, some a group change, some a training change, some all of the above. The problem I run into is that I will sometimes process hundreds of changes a week, sometimes only 10-20 so I almost have to use datasheet view for mass edits. I'm relatively new to Access and I'm having a hard time getting my form to allow this level of flexibility and to update all fields needed.

When I build a form that includes more than two tables (let's say I want to update a Manager and a Business Title), the form will not work and populates nothing. I believe it's because Access wants there to be an existing record to match to across all three tables and there will not always be.

View 4 Replies View Related

Forms :: Create Form That Will Update Multiple Tables?

Jan 31, 2014

How do you create a form that is not tied to one single record source? In other words, I want to be able to select the record source that it updates. I have a bunch of tables that have the same data structure but are separated due to geographical nature among other reasons. Is there a way to do this?

View 10 Replies View Related

Tables :: Stock Update - Calculated Fields And Lookups

Aug 7, 2013

We have our access database with a bit of a messy structure?

We use our database to record sizes of our product. I am hoping to improve it by adding the items we have in stock to prevent manufacturing more.

Basically our main database called "Make & Model 1" has a list of various makes and model numbers, each model number lists various information needed to manufacture a replacement part.

Customers order the part and these part details are entered into a table called "Order Detail" What I would like to happen is that when the details are entered a calculated field adds the data entered to a text string. I need to match the text string to the same text string in a table called "stock" as there could be one part that matches hundreds of models.

Basically the "profile" "Colour" "height" and "width" make the string and this is what I need to match and tick a box / populate the number of items in stock. Eventually I would like this to reduce by the amount ordered but lets do one step at a time.

I am using Access 2010

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved