General :: Advance Sum IIF - Matching Names In Two Tables

Sep 10, 2014

I have 2 table

Table1 only one column
name
AA
BB
CC

Table2 two column
name number
AA 1
AC 3
AW 8
AA 6
AA 5
DF 4
EE 8
CA 9
CC 7

I want to sum the table2 number when the table2 name match any name in table1

So the answer should be 1+6+5+7

View Replies


ADVERTISEMENT

General :: Copy Of Field Names In Tables

Jul 8, 2013

I have a db with about 30 tables. What is the easiest (if possible) to copy field names to paste it into Exel or Word? I need to distribute it to other people.

View 2 Replies View Related

Tables :: Deleting Matching Records From Two Tables

Dec 5, 2012

I have two tables "Master List" and "Audit". I want to delete the records from the "Master" that match those in the "Audit". I am using Access 2010 and have used it often but have built very few queries.

View 3 Replies View Related

General :: Matching Data Error

Mar 5, 2014

I am trying to aput a stock number into a form called (products) but it tells me there is no matching number in another table ( stocklist). yet that number is in another table (stocklist.

View 2 Replies View Related

Matching Values From 2 Tables

May 4, 2007

I have three tables: tblProducts1, tblProducts2 and tblProductSales.tblProducts1Code CostABC 20BVC 35ABC 30tblProducts2Code CostABC 10BVC 55ABC 20tblProductSalesCode RevABC 70BVC 25ABC 20BVC 15DCC 33I want to produce a query that looks like this:Code Rev Cost ProfitABC 90 80 10BVC 40 90 -50DCC 33 0 33How can I do this?Thanks,Jon

View 1 Replies View Related

Two Tables - Data Matching

Oct 21, 2007

Hi,I have two tables with these set of data:Table1Filed1 Field21000 A1001 B1002 C1003 D1004 ETable2Filed1 Field21000 A1002 C1003 D1005 F1006 GI need to create 3 Tables with following out put.1. Data that are common to both Table1 & Table22. Data that are in Table1 but do no exist in Table23. Data that are in Table2 but do not exist in Table1 Can anyone help me to find the answer please.CheersBud

View 1 Replies View Related

Matching Two Fields In Two Tables

Nov 13, 2006

In a database I have two tables, one is linked to an excel sheet (our customers order) and the other is created via a "make-table query" from our business system.

In both tables I have the customers part numbers and neither contain a primary key.

What I need to do is compare the part numbers in both tables to find if a part number is present in the order but not in our business system.

I just cannot figure out how to do this.

Any ideas are greatly appreciated

/twallstr

View 2 Replies View Related

Help Comparing And Matching Tables

Dec 18, 2004

I have 3 tables that all contain Car registration numbers.
Table 1 contains just Reg numbers. Table 2 contains Registration numbers with an additional 2 columns of data. Table 3 also contains Registration numbers with an additional 2 columns of data.
I need to compare the reg numbers in Table 1 with Tables 2 and 3 and where the same Reg number appears in either of Table 2 or 3 display the results in a new table / query.
ie, Table1 Reg, Table2 data , Table3 data Note there are some Reg numbers that will appear in all 3 tables.

any help appreciated.
Malc

View 2 Replies View Related

Matching ID Values Between Two Tables

Jun 4, 2014

I have two tables, one has two fields:student ID and student name.its kind of like this:

1 Mark
2 Tom
3 Franklin

the other table has three fields: student name, student classes, it goes like this:

Mark calculus
Mark Biology
Tom Statistics

Franklin Calculus
Tom Chemistry

what I want is for the second table to have its related id from the first table so it could be like this:

1 calculus
1 biology
2 statistics
3 calculus
2 chemistry

I cant simply make find and replace because the records are a lot is there another way should I relate the tables of something how will it work?

View 8 Replies View Related

Find Matching Entries In Other Tables?

Dec 10, 2007

Im using Access 2000.

Essentially I want to find out which of the entries in my master table have matching entries in my other tables, and list the ones that do.

So if I have an entry in the master table for “productA”, and there are also matching entries for “productA” in tables “SupplierC” and “SupplierD”. I want to perform a query that will output a list showing “SupplierC” and “SupplierD” (I have A & B tables but if there isn’t an entry in them for “ProductA” I don’t want them on the list.)

I intend to use the results to populate the values of a combo box in future so I require the list to be in a single column, rather than across many columns. Does anyone know if this is possible?

My master table is called “OurProductsTable” and the four supplier tables are called “SupplierA”, “SupplierB”, “SupplierC”, and “SupplierD”.

Each Table has a primary key called “ProductID” and I have linked them together on the relationships screen.

I’m not sure if this is the proper method but I also made another field in each of the supplier tables called “CompanyName” and set the default value as the name of each supplier, so if the entry for supplierC matches the master table entry I can return the “CompanyName” value of “SupplierC”.

Here’s what I thought the code should kind of look like but I don’t know how to apply it properly in a query:

View 4 Replies View Related

Modules & VBA :: Text Matching Between Two Tables

Jun 5, 2013

Well, I have two tables in an access file one table having customer data base along with the customer name and another table only having the customer name. Now the table having only customer name need not be having the exact customer name in terms of spelling or spaces but both of them will same for e.g. table 1 - Apple and in table 2 - app let. Therefore the system should match this and throw out the results into a different new table as matching results.

View 2 Replies View Related

Queries :: Matching Two Tables With Count

Jan 20, 2014

trying to create a query in which I can select a count across two tables with matching postcodes.

Table 1 : Address database with column called 'STRIPCODE' (e.g. ME8, ME9, ME10)
Table 2 : Area Code table; each column has a list of area codes to match to the STRIPCODE column. (e.g. MEDWAY column will have all of the relevant area codes)

I would pretty much want a count of each match as below :

STRIPCODE
MEDWAY 650
BLACKPOOL 563
HULL 352

Have a few hundred areas to match and tired of going through these manually and entering counts!

View 3 Replies View Related

Matching (find All In Common) Two Tables Of Titles

Aug 12, 2005

Hi,

I have two tables of titles (DVDs and CDs). Each table has a price associated with each title in an adjacent column. I would like to match the titles between them and compare prices. Any help would be greatly appreciated. Thanks. EDS

View 2 Replies View Related

Queries :: Count Matching Postcode Between Two Tables

Sep 1, 2014

I have two tables, one being an 'Address' file and the other an 'Area' file which is a list columns ranging from 1-400 with groups of district level postcodes. For Example; column 1 will have postcodes such as BN1, BN2, BN3, BN4, BN5 etc. Each column has a separate group of postcodes.

Now, my 'Address' file also has a column within this labelled 'District' in order for me to create a straight join (between column number and District) in a query to count each group individually, but of course, do to this 400 times becomes quite tedious! (to say the least)

I would require the outcome to be as follows :

Area file - Count
1 - 469
2 - 201
3 - 0
4 - 3598
5 - 268
. - 101
. - 8936
. - 563
399 - 287
400 - 41

View 5 Replies View Related

General :: Merge Two Fields From Two Databases That Have Matching Two Data Ranges

Mar 25, 2014

I have two databases (files). Each file has a format like the one below.

File 1:
chr start end
chr1 1000 2000
chr2 3000 4000

File 2:
chr start end
chr1 1500 3000
chr2 3750 4000

I want to be able to merge the two records together if the field chr matches between the two files plus if there is an overlap between the start number and end number from each file. For instance the first record from each file would match because the range from 1000 to 2000 of file 1 has numbers consisting of 500 numbers (1500-2000) that are also present and overlap in file 2 (1500-3000). I possibly cannot use < or > since the ranges from each file will vary to different degrees. Perhaps there is a between function that might work...

View 7 Replies View Related

Compare Data In Different Tables And List Non Matching Values

Nov 2, 2007

Hi

I am trying to compare data in two different tables and list the data that does not match. Not sure if this is possible. Details below

Table 1

xyz - A1 - Do not use
ABC - A4 - Use

Table 2

123 - A1

The result of the query should show me

A4 (as this does not appear in table 2

I am not too familiar with Null values as there will be many null values that i want to ignore.

Any help will be appreciated.

View 4 Replies View Related

Queries :: How To Join Tables With No Matching - Unique Fields

Jun 16, 2013

I am undertaking an analysis of corporate mobile phone data based on data from the phone provider. The base data consists of a number of monthly text files at transaction level for voice calls, data usage, billing/tariff information, international calls/transfers etc. I have set up VBA code to import the text file data into a number of Access tables.I would like to have a way of joining these tables but the only common field is the phone number (a text field with the groups of numbers separated by hyphens).

I confirmed that joining the tables on the phone number text field does not work.My idea was to create an additional table with just one row for each phone number and link that to the other tables by the ID in the new table. I was able to create this table [PhoneNumbers] (by creating a totals query of the phone numbers from the main call transactions table, I then dumped it into Excel and then imported it into a new Access table with an auto-generated ID column).My problem / challenge is how to get the ID column from my [PhoneNumbers] table to appear in each of the other tables so that I can join them effectively. In the Excel-world, I would have used a vlookup function.I even thought of performing this as an interim step in Excel but there are too many records / rows in some of my tables. It seems that the dlookup function is not what Im looking for and even if the IIF function is suitable, I cannot get the syntax to work for me.

View 8 Replies View Related

Queries :: Update Query Using Matching Criteria From 2 Tables

Oct 18, 2013

I have 2 tables that must be involved in this query. Both have the same fields; one is a temporary table created from an Excel import which will be deleted later, the other is the permanent table.

tblStoreProducts is the permanent table. It has a 2-field Unique index; there can only be 1 of any ProductKey for a StoreKey (there can be multiple ProductKeys within a StoreKey, and multiple StoreKeys for each product, but there can only be 1 entry for each unique combination of ProductKey/StoreKey).

tblImportToStoreProducts is the temporary table. It holds all of the ProductKeys for one StoreKey.

My query needs to identify any ProductKey in the tblStoreProducts that does not exist in the tblImportToStoreProducts for that StoreKey, and then it must set the MaxUnits field to 0.

Basically, the temporary table is this years' inventory for a particular store. If a product was in that store last year but it isn't there this year, the quantity must be set to 0 because the ultimate aim is reporting hazardous materials.

View 1 Replies View Related

Tables :: Update A Specific Record Based On Matching Primary Key ID?

May 22, 2014

My problem is that I am trying to update a field (called 'Sold' which is a yes/no checkbox column) for a specific record whenever an event is triggered. I have two forms (derived from two tables), one is called frmInventory and the other is called frmSales. In frmSales, I made a combo box called 'cboItemID' that allows the user to select from a list of items from my inventory table. Each selection from the list has 4 properties, the first of which is the 'Item ID' from the inventory table. Lastly, I have a field in both frmSales and frmInventory called 'Sold' as mentioned above. What I want to do is that whenever I check/uncheck the box in the 'Sold' field in frmSales, I want the 'Sold' field in frmInventory to check/uncheck as well, but only in the record with an 'Item ID' that matches the 'Item ID' from the combo box selection. In other words, I want to match the 'Sold' field in frmInventory with the 'Sold' field in frmSales, but for only the record that has the same 'Item ID' primary key as the one I picked from my selection in the combo box from frmSales.

how to reference another table and check whether or not it's 'Item ID' primary key is identical to the one I specified from the combo box, and then take action to update the 'Sold' field if the IDs match.

View 1 Replies View Related

Find Matching Dates In Tables A And B / Then Populate Blank Fields In A From B

Apr 30, 2012

I have a table tROE with a field listing all dates starting 1/1/10 to date (populated), and three fields for currency exchange rates [USD], [RSD] & [EUR] which are empty and need to be populated. I have another table tROEPartial that has the exchange rates for some of the dates starting 1/1/10 but not all. Their structures are identical. I want to add the exchange rates from tROEPartial to tROE where the dates match, leaving the unmatched fields in tROE blank.

View 3 Replies View Related

Date Advance

Aug 4, 2005

I have a very generic form I use to track all my To Do things on a daily basis. The form has the following fields: fldComplete, fldDueDate, and fldSubject.

The fldComplete is a check box and the fldDueDate is of course a date data type.

What I would like to create is a query that once you click the fldComplete signifying that the task is complete:

1. The record is removed from the form.

2. The fldDueDate advances either annually, monthly, quarterly etc. which automatically goes to the end of the form in sequential order.

Any help is much appreciated.

ChiefRetired

View 8 Replies View Related

Advance Query

Apr 12, 2006

I have been struggling with this one a while now and need to throw this open as im Stuck!

i have a database of domain names that I currently own however i need to be able to report on the TLD (eg .co.uk .com. me.uk) part of the domain. in the database the field domain is held in the format "imstuck.co.uk" i need a query that will strip the domain part and just return the TLD in a seprate field.

I have used numvers of functions but cant seem to get the right format for it to work

Help!

Kevin

View 4 Replies View Related

Tables :: Auto-populate By Matching Data To Another Table And Selecting Corresponding Field

Sep 16, 2013

I have with my database. It's holds cost data including purchase made in foreign currencies which need to be converted to GBP using the correct exchange rate so a variety of reporting & stats can be performed.I have a table called Costs within which there are 2 fields

Purchase Currency
Exchange Rate

I also have another table called Exchange Rates 13/14 within which there are 2 fields

Currency
Exchange Rate

When a value is entered in the Purchase Currency field on the Costs table (this is a look up field linked to Exchange Rates 13/14 so it shows the listed currency in drop down) I need the database to automatically populate the Exchange Rate column in Costs i.e. match the value in the Purchase Currency field to the Currency field in Exchange Rate 13/14 and populate with corresponding Exchange Rate from Exchange Rate 13/14.I have tried the following and none work:

SQL Tried

1.
UPDATE Costs
SET ExchangeRate = [Exchange Rates 13/14].[Exchange Rate]
WHERE Costs.[Purchase Currency] LIKE [Exchange Rates 13/14].Currency

2.
UPDATE
Costs
SET
ExchangeRate = [Exchange Rate]
FROM
[Exchange Rates 13/14]
INNER JOIN
[Exchange Rates 13/14]
ON
Costs.[Purchase Currency] = [Exchange Rates 13/14].Currency

3.
SELECT [Exchange Rate]
FROM [Exchange Rates 13/14]
WHERE Costs.[Purchase Currency] LIKE [Exchange Rates 13/14].Currency

I know it is possible to have a drop down for Purchase Currency which shows 2 columns (both Currency and Exchange Rate) you can then use the exchange rate figure for a calculated field. The problem I have is that I am importing data into the costs table from excel. In Excel I can only have 1 value in the Purchase Currency column on the upload template. If I just have Euro in this column the database does not match it to the Euro in the Purchase Currency drop down and also store the correct exchange rate.

Or is the alternative to put this into the calculation of GBP Unit Cost where this somehow matches the Purchase Currency in the Costs table to the Currency field in Exchange Rates 13/14 tables and uses the appropriate exchange rate from Exchange Rates 13/14 to calculate GBP Unit Cost in Costs table.

View 4 Replies View Related

Booking Too Far In Advance Or Too Close

Mar 24, 2006

Hello everyone, if anybody could help me I'd deeply appreciate it.


Booking ID = the time when it is booked over the phone
Hiring ID = the time when the event is to be held

Basically I have to make some booking dates, and use January and February 2006 as test data. My only dilemma is it says that the booking dates must not be booked more than 8 weeks before the hiring, and at least 1 week before it. So if someone wanted to the hiring for 01/01/06, then they wouldn't be able to book before 01/11/05, but before 25/12/05. Can anybody help me? Thanks. I need it so that whatever the hiring date is, the booking date has to be no more than 8 weeks in advance, but 1 week before the hiring.

View 4 Replies View Related

Setting Up A Paid In Advance

May 5, 2006

I have a problem with figuring out how to implement what I call “Paid In Advance”. If a customer pays 4, 5, 6, or 12 months in advance, I for some reason can’t think of how to set this up with tables, queries, forms, and reports. The example that closely matches my db is “Order Entry” from access sample db’s.

Tables are as follows:
tblCustomerDetail
tblCustomerHistory
tblPayments

For every customer (tblCustomerDetail) there are multiple service records (tblCustomerHistory) and for every service record there are or can be multiple payments (tblPayments) for that one service record.

Just like in “Order Entry” where Customers have multiple Orders and then one or many Payments for that one Order. (Pretend that Order Details is in the Orders table.)

The problem that I’m having is trying to come up with a way to assign the “Paid In Advance” money to the customers account without assigning it to a service record or payment. I can’t assign it to a service record because it hasn’t been serviced yet. And I can’t assign it to a payment because the service record generates a new record in the tblPayments when a new service record is entered, and besides that wouldn’t work because the “Paid In Advance” money would only be applied to that one service record.

I hope everyone is following what I’m saying.
If anyone has any clue as to what I am trying to do, please feel free to help me.
As always any help would be greatly appreciated.

Thanks

P.S. If anyone knows where there is a sample db of what I am trying to do, I would be grateful if you could post the link in your reply.

View 4 Replies View Related

Modules & VBA :: Cannot Get Loop To Advance

May 11, 2014

Here is the code:

Private Sub Form_Load()
Dim rs As Recordset
Set rs = CurrentDb.OpenRecordset("select * from tblpatient, dbOpenDynaset)
If Not (rs.BOF And rs.EOF) Then
rs.MoveFirst
Do While Not rs.EOF
' do stuff
rs.MoveNext
Loop
rs.Close
Set rs = Nothing
End If
End Sub

I have watched it step through on debug and it does everything right for the first record, but it seems to come back to the same record.

View 3 Replies View Related







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