Updating Data In Queries

Jan 31, 2005

Each month I get 20 new tables to query data from. The field layout for my query is the same each time, with about 40 fields in total. Because this is the same query each time (and only the data in each table changes), how can I best set this up. I.E. each time I run the query, I have to go back in to the design view and select the new table for each field (in this case, update all 40 fields with the new table name). Surely there is a quicker way to do this.

Thanks,

View Replies


ADVERTISEMENT

Queries :: Data Comparing And Updating Incorrectly

Apr 17, 2013

I have 2 tables one Access, one FoxPro both containing similar information. The idea of my query is to compare both tables and update the Access table if the value in the FoxPro table has changed. This works fine for a number of similar queries that I have. However, intermittently, this query will see two values as different when they are exactly the same and replace the value in the Access table with a seemingly random value. I know the "Random" values are from other records within the table but cannot see any link between the values.

View 2 Replies View Related

Queries :: Copying / Updating Data From A Database Table To Another

Jul 28, 2014

I have a MS Access table containing Dependent social security numbers but some of the dependents social security numbers are blank.

I have a MS Sql Database that contains a table with most of the missing MS Access table dependents Social Security numbers.

How can I take the Dependents social security number from MS Sql Database and copy/update the MS Access table.

I tried the sql code below created from MS Access and it matches 453 records out of 460 dependent social security numbers but how do I update qryGHIAccuracyFile_MissingDepSSN.SSN with the social security number from dbo_depfile1.dep_depend_ssn

Code:

SELECT dbo_depfile1.dep_depend_ssn, qryGHIAccuracyFile_MissingDepSSN.SSN
FROM qryGHIAccuracyFile_MissingDepSSN LEFT JOIN dbo_depfile1 ON qryGHIAccuracyFile_MissingDepSSN.MemberSSN = dbo_depfile1.dep_ss_nbr
WHERE (((dbo_depfile1.dep_first)=[FirstName]) AND ((dbo_depfile1.dep_last)=[LastName]));

Updating MS Access table dependent blank SSNs with SSN in MS Sql Database.

View 2 Replies View Related

General :: Updating Table Data With Data From Preceding Entry?

Jan 5, 2013

My question is this: I have a table where I'm entering employees' hours worked. Basically, it's something like this:

ID WorkerNumberDateworkedTimeStartTimeEnded
121/2/201310:00:00 AM3:00:00 PM
221/3/20132:00:00 AM11:00:00 AM
321/4/201312:15:00 AM11:30:00 AM
421/5/201310:25:00 PM11:00:00 AM
531/2/201311:00:00 AM3:30:00 PM
631/3/201312:00:00 PM10:00:00 PM
731/10/20137:00:00 AM4:00:00 PM

I have a query that (easily) determines how many hours an employee has worked on any given day. What I can't figure out at all, is how to write a query that can figure out how much time an employee had off in between shifts.

Thus far I'm able to run a query that separates this main table into individual workers by their id numbers, but can't figure out how to determine time off between shifts - as the last hour worked one day, and the first hour worked the next day are on two different lines (they are two different table entries).

View 4 Replies View Related

HELP!! Trying To Nomalize Existing Data By Updating Data Into New Fields

Dec 19, 2006

Hello Tech gurus,

I have a database with existing data, that is not normalized, :eek: and all the data is in one field... This what I am dealing with:

As you notice the first row of data in field1 C10A CHOLEST&TRIGLY has 3 spaces to the right the next row ALTORVASTIN has five spaces to the right, the next line LIPITOR has 7 spaces to the right, and so forth, hopefully you get at what I am trying to do, I just looked at the data and it is not showing up in view of the leading spaces, but I am trying to move the data based ONLY on the position of leading spaces, example all data that has 3 leading spaces would go into its own separate column, and all data that has 7 leading spaces would go into a separate column, I have tried to use the left, mid, len functions but I cannot figure out how to move the text and keep it whole only by data position of spaces.

Field1:
C10A CHOLEST&TRIGLY
ATORVASTATIN
LIPITOR
PFIZER
SIMVASTATIN
SIMVASTATIN TEVA
TEVA
M1A ANTIRHEUMATIC N-STEROID
ETODOLAC
ETOPAN
TARO PHARMA
Thanks so much for your help... :confused:

Nana :D

View 10 Replies View Related

Updating A Mulitple Queries

Nov 10, 2005

Hello I am new to Access and slowly finding my way round.

I have built 30 queries which eventually build two Union Queries of which each query as a slight different criteria.

In all 30 queries there is an indentical Field name called Arrived. What i want the user to be able to do is change the criteria in the Arrived figure throught a message box. So far the criteria is in the field is:

>=date()-3

This will show me everything 3 days ago. What i want to do is to let the user check what happened 5 days ago 10 days ago. I know i can create the following to solve the message box:

>=date()-3-[Enter in the days less than today]

Is there away to update all 30 queries at once with the same code?

View 3 Replies View Related

Updating Queries Dynamically

May 23, 2006

Hi Guys

my database is essentially a questionnaire of around 200 questions. I'm trying to add a 'light' version to it.

I've added a 'include in light verion' tick-box to all the questions and a 'light analysis' tick box on the registration page.

The questions are all genertated via queries pulling out the appropriate ones as required. What I'm tying to do is add to these queries so that if the 'perfomr light analysis' tick box is ticked only those questions that have been indicated as light are included, and if it's not all teh questions are included.

I can do either-or but not both dynamically

Can anybody help?

Thanks
scube

View 1 Replies View Related

Updating Reports And Queries

Sep 27, 2006

I am updating an existing distributed access database.
I have made changes to an existing report (from my workstation - I have admin rights on the DB). The changes show up on the database. However when a client generates a report, the changes do not show up. What can I do??

View 4 Replies View Related

Updating Fields After Importing Data

Feb 13, 2006

Hi,

How can I get a field to update automatically after data has been imported into the record.

Manually it works using the DLOOKUP in the "After Update" properties but this does not work when importing data.

TIA

Mike C

View 4 Replies View Related

Updating Tables While Data Is Viewed

Apr 18, 2007

I have created a Production Tracking database for my company using
Access 2003. Everyone here uses Access 2000, so I have saved the file
as an access 2000 database. I am importing three tables from an ODBC
connection. These tables are being update by another department
constantly. I am using a centralized form for users to view the
information.

If the users are viewing the information and we try to update the
tables they are viewing, we get an error. My question is: Is there a
way around this problem?

This what I have done:
In the module I wrote, I am importing the tables, then renaming them
to the tables the users are viewing, and then altering the structure
of one of the tables. We cannot use linked tables, the reason is we
have only three licenses to access the software through the ODBC
connection. So as soon as three people open the access database they
take those three connections.

Any Ideas?

Thanks,
Phil

View 4 Replies View Related

Updating Between Fields Of Different Data Types

Jun 21, 2005

WorkID is a look-up field, so its Data Type is Number.
In the same table, DailyGrind is a field with the Data Type of text.

I would like to update WorkID with the jobs in DailyGrind.

Surely there must be a way to do it, gurus?

View 4 Replies View Related

Updating Fields In Table With New Data - Help

Jun 17, 2007

Hello

I have a table with 3 fields:
- ID no (primany key), Time1 and Time2
I have 3 records with ID no 1 to 3.
So my table look like this

ID no: Time1: Time2:
1 [emty] [emty]
2 [emty] [emty]
3 [emty] [emty]

I have an Excel document with the data for field Time1 and another Excel dokument with the data for field Time2. Excel doc1 have 2 colums named ID no and Time1. And Excel doc2 have 2 colums named ID no and Time2.

How do I import/update these data into my table?

I have tried wiht a adding-quiry but it only works if the table is complety emty and only with one Excel doc. Trying the second Excel doc afterwards only makes an error and no fields are updated.:confused:

View 4 Replies View Related

Inserting/updating Data From A Csv File

Dec 8, 2005

Hi

I have recently had to add a new field to a FIRM table in our contact database, Firm.PhoneNumber (please don't ask why it wasn't there before!). The primary key in this table is Firm.FirmID.

I have a list available to me in .csv format that contains all the phone numbers I need, it has two 'columns', labelled FirmID and PhoneNumber.

The process is surely a simple one, I just need to update/copy/insert the corresponding phone numbers from the csv file into the Firm.PhoneNumber field. I won't bore you with what I've attempted thus far but could someone please provide me with the quickest possbile method for achieving this task?

Many thanks

Stuck21

View 1 Replies View Related

Linking Forms Together - Data Updating

Oct 13, 2005

I have a database for the clients at my work place.

The main table with PK ie FRED001 has main client details (address DOB etc) then i have numerous other tables ' relationship one to many' with their investment details (lots of investments per client), appointment details, pension details, health details etc. The data base works fine in table form all the links master to child work fine but now i need to let the rest of the office loose on the system i am trying to create more user friendly form system with command buttons etc

I have created a form for each table some of which have sub forms in etc on their own they appear to work fine you can view all the records and add a new one

I am having problems linking the numerous forms together and when they are linked together (i also need the child form to auto insert the code from the master form? since it comes out blank at the moment!). At the moment i have the main form with command buttons on it to open up the child forms. this works i can see the current investments already entered on the database but it will not let me add a new investment or a new appointment etc it says that by adding a new invesment under the client code i am breaking the code no duplication rules?? but the child tables are set up with the clientcode allowed to be duplicated ??

I need to have each child table in a new form really since there is far too much information for it to all be on sub forms within the main table.

I have tried to also put the forms on tabs but i get the same result.

basically i need to be able to open up the main form at client X then using command buttons or page tabs move to both view their existing investments and add any new investments. Im sure it is something very simple that i have done wrong but i have been trying to solve this for ages now and its getting me more and more wound up ahhhhhhhhhhhhhhhhhhh!!

I have also tried inserting under tabs a small subform list for each table/formie policy number, surname etc to fill in new policies and the name with a command button to the form ( which should then have the details in?!?!) since i figured if these details were filled in then when i went to the form they should be there but tthat doesn't work either

thanks for any help or suggestions

:confused:

View 1 Replies View Related

Updating Table Data Using A Combo Box

Sep 4, 2006

Hi all
I have been nutting out this problem but have been unable to find a solution, even my learned colleague is at a loss to help. This is an data update query using combo boxes and forms.
I have 2 databases, Data and App, I have linked 2 tables, Main and Supervisor from the Data.mdb to the App.mdb. Supervisor has 2 fields ID and Name. Main has multiple fields but is linked to Supervisor by the ID field. I have a query that gets details from the Main Table and this is entered into a form. I deleted the SupervisorID text box and inserted a combo box using the wizard, it gets its data from a query that gets details from the Supervisor table showing the Supervisor name, the ID field in the dropdown is hidden. The combo box selection is held in the SupervisorID of the Main table.
What I want to do is change the Supervisor name using the combo box however I am unable to select another name from the dropdown list.
I have tried changing the Data Entry property of the form to Yes, this did not work. Allow edits is set to yes. I have tried adding another combo box which gets the data straight from the Supervisor table but I have the same problem.
Can anyone help, we think it is a simple property setting but all we have tried has failed to date. Thanks in advance.
Craig

View 4 Replies View Related

Form Not Updating After Data Entry

Dec 20, 2006

Hi
Can any one help me with a quickey. I have a form which shows short details of a building ie name town postcode etc. I have another form with 3 subforms to be able to enter new details of a building, the new client and the new agreement. This works well and is feeding the new data into the correct tables. When I reopen the short detail form it doesnot display the new records. I have a short piece of vba which allows ne to see the full details of a site when I click on the site name.
A quick reply would be much appreciated.
Thanks
ChrisD

View 2 Replies View Related

Updating Split Data Tables

Oct 12, 2004

This has to be a common problem.

I have an environment where I have two databases. One holding tables (The Data) and one holding everything else "The Programs" (Forms, Queries etc)

When the application gets enhanced I currently have no problem updating "The Programs" since I can just copy the new MDB on top of the old MDB.

This is not the case with "The Data", if I need to change any of the tables (since they contain live data, that is modified all the time) I have to physically connect to the machine holding the Data.MDB and modify the tables. The problem is there are getting to be many locations where these changes need to be made.

Is there any way to update the tables from a script (I used to use SQL to update remote tables in a mainframe world)

Thanks

View 3 Replies View Related

Data Entry Form/SSN Not Updating

Nov 13, 2006

I have an issue, I have a main data entry form that does not allow new SSN# to be entered in that particular form. So I added a button that brings up the form which allows a person to put in the new SSN# and person name. The problem is when that form closes and the other form tries to get the information from the pulldown. It is not shown there. I have to manually close and open the form again so that the new updated information can be on the main data entry form.

Is there a way for the information to be updated when a new SSN# is put into the database so a person don't have to close the main form and open it back up?

View 4 Replies View Related

Modules & VBA :: Updating Table With New Data Value

Aug 11, 2015

I have a VBA script that looks at a date on a form, adds a certain number of months (selected by the user). at the moment i can output the new data to a message box. I want to update a table with the new data value.

This is the code i have so far.

mySQL = "UPDATE job master file " & _
"SET [BBDate] = " & newdate & _
"WHERE [job name] = " & strname

View 10 Replies View Related

Queries :: Updating Table From A Query?

Jan 6, 2014

I have a table and a query both of which have the same [Resource ID], [Resource Name] fields.

I am trying to update the [CBL_1_Date], and the [CBL_1_kW] fields in the table with the [CBL_x_Date] and [CBL_x_kW] fields of the query. The problem is that when I try to run the query I keep getting "Operation Must Use and Updateable Query" error.

here is the SQL Code

UPDATE tCBLAggregation
INNER JOIN qBestof4CBLs_avg
ON (tCBLAggregation.[Event Date] = qBestof4CBLs_avg.[Event Start Date]) AND (tCBLAggregation.[Resource ID] = qBestof4CBLs_avg.[Resource ID])
SET tCBLAggregation.CBL_1_Date = [qBestof4CBLs_avg].[CBL_x_Date], tCBLAggregation.CBL_1_kW = [qBestof4CBLs_avg].[AvgOfCBL_x_kW];

View 1 Replies View Related

Queries :: Updating A Large Table?

Mar 1, 2015

This really isn't a large table by Access standards, as it has only about 1 million records, but nevertheless it's taking a long time to run the update query. Here's the query:

UPDATE [Db] INNER JOIN [Small Table] ON [Large Table].text1=[Small Table].[text1] SET [Large Table].[text2] = [Small Table].[text2];

[Large Table] has about 1 million records and [Small Table] has 10 records.

View 9 Replies View Related

Queries :: Updating Table With A Count Or Sum

Aug 15, 2015

i am trying top create a stock take form. the form is now set up so each time an item is scanned a new record is created in the tblStockUpdate. i ow need to create an update query that updates tblItems with the correct quantities.

the relational data will be the barcode and is unique to each record in tblItems. because each time an item is scanned a new record is created i need to count records grouped by barcode or sum as each new record has a 1 as default in the qty column.i have created a qry that sums the records by group(Barcode) but now i need to update the tblItems quantities. update queries have always troubled me and this one is beating me at present.

View 3 Replies View Related

Queries :: If Statement Not Updating In Query

Jun 23, 2015

I have a query based on a table that has a column called Calculated Card Expiration:

IIf([Card Type Issued]="PIV",[Issue Date]+1095,IIf([Card Type Issued]="Non-PIV",[Issue Date]+1095,IIf([Card Type Issued]="Flash",[Issue Date]+365,Null)))

It worked fine when I ran the query the first time, but now when a Card Type Issued and Issue Date is added or changed it doesn't work.

View 5 Replies View Related

Queries :: Updating A Table Using Wildcards?

Jun 21, 2014

Is it possible to update vlues in a table using wildcards. I want to use a query to search for certain records that meet a certain criteria and modify these values like changing particular dates in the date field to new values.

View 1 Replies View Related

Queries :: Updating Lines In A Query

Sep 26, 2013

I have created a query which is based on 2 tables.I now want to use the query to update content as needed in one of the tablesWhen I try to do this it says, Operation must use an updateable query..I used the update feature but it still says must be created in updateable query.

View 4 Replies View Related

Queries :: Updating Table Through Query

Aug 9, 2014

I'm working on a project management database for my fathers small business. Data Entry goes as follows: Users enter a Work Order, and all the parts that must be created for that work order. The parts have different processes (tasks) done to them to be created. The database runs a simple system like this as we want it to work. I am now attempting to allow handling of more advanced work orders. Specifically, some parts require the completion of multiple other parts before they can be created.

Here is how the database should handle these events:

1) User clicks button named "requires other parts" when entering a new part.
2) On click a subform is opened that allows the user to enter which other parts need to be completed first.
3) Once all of the parts are completed the next part can begin.

This is my current solution:

1) A query calculates if a part is complete
2) Some form of logic looks up to see if all the required parts are completed. If the answer is yes, a field named ready changes to "Yes" and if the answer is no, a field named ready changes to "no"

View 9 Replies View Related







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