Topics Search

Compare values in in two tables fields

Compare values in in two tables fields
Views: 3
I need to create a procedure which will be able to check if some value in field of one table doesn't exist in the field with the same name and data type in other table.
I'm using two RS-s method to loop trough the data of both tables
Sponsored Links:

Similar posts...


Compare two tables and find records without matches

Compare two tables and find records without matches Icon
Sometimes you may want to compare two tables and identify records in one of the tables that have no corresponding records in the other table. The easiest way to identify these records is by using the Find Unmatched Query Wizard. After the wizard builds your query, you can modify the query's design to add or remove fields, or to add joins between the two tables (to indicate fields whose values should match). You can also create your own query to find unmatched records, without using the wizard.

Compare values in two columns present in seperate tab

Compare values in two columns present in seperate tab Icon
How can I compare values in two columns (columns are in different tables) ? I also want to display the values that don't match in a separate table.

For eg:

If values in Column1 from Table1 does not match Values in Column1 from Table2 then display those values in a separate table

Is there a way to do this?

Queries to Compare Two Tables

Queries to Compare Two Tables Icon
I am trying to compare the data in two tables. The columns are the same, deleted rows, or changes in specific fields across the two tables.

The Query Wizard for Unmatched doesn't quite accomplish what I am trying to do. If TableB is missing a row from Table A then it will return new rows if I select the two tables in the proper order (reversing will return nothing).

I still do not receive anything if simply one field for one row was changed (everything else the same).

comparing 2 fields from 2 tables

comparing 2 fields from 2 tables Icon
I have two tables and they have 3-4 columns (fields) each.
Table1 - fields: Name, address, city, country
Table 2 - fields: Name, occupation

I need to compare the names in both these tables and see what names from table1 are not in table2.

Compare input to table of ranges

Compare input to table of ranges Icon
I have a form that takes user input (about 20 text boxes) and writes to fields in a table. Form is locked to one record per instance.

I need to compare the user input to values in a table. The table is structured so that each record is relative to one specific field in the table (also one specific textbox on the form)and each record has three fields with values that determine a 'range'.
What I need to do is compare the user input (for each field) to the associated ranges in the table to 'grade' the input. The result will be to color textboxes, labels, etc. on the form based on this grading.

What is the most efficient way to do this?
Should I read the grading into an array and then compare each field (textbox on the form)?
Should I compare one field at a time to one specific record? (seems code intensive and very unforgiving when changes come)

Compare records in 2 tables

Compare records in 2 tables Icon
to all
I am trying to solve the problem of reviewing records from 2 different tables. Both tables have the same fields both in Name and type. There is 6 fields to each table to compare. Each field can have a different number up to 42. I am trying to see how many of the numbers in a given record for table 1 matches the records in table 2. below is an example of what I am doing.

Tble1 Tble2
N1 = 2 N1 = 5
N2 = 24 N2 = 2
N3 = 5 N3 = 10
N4 = 9 N4 = 31
N5 = 10 N4 = 36
N6 = 29 N6 = 28

Using the if statments I am currently using this will deliver me 3 matching numbers on 2, 5 and 10.

As I said I am using IF staments to this right now. Is there a better, more efficent way to accomplish the same thing. Tble1 is a small table but Tble2 has a large number of records and process time is about 25 minutes.

Compare tables between two databases

Compare tables between two databases Icon
Im back again. This time I want to compare two tables in two different databases. I have an archive database and I want to make sure that both tables are equal before I delete the information from the production databases table. Ive been looking around and have been finding that I should be using a UNION query but I dont know how.
Lets I have B_Table in the Archive database and A_Table in the Production database. I need it to compare and let me know if there is anything that does not match but without linking tables or anything like that.

Subtract values from 2 tables

Subtract values from 2 tables Icon
I have a query. how do I subtract numerical values btw tables? pls look at the atatched file. I have 2 tables (Table1 and Table2) with several fields [ABC], [XXX], [YYY] . in both tables. I need to subtract the values under these but I need to get what is displayed in Query1 showing individual difference (not overall difference - if so I could have combine the fields into one field like "ABCXXXYYYZZZ " to get the value of 38. I could do this in excel and just pivot out the dataset to get the individual difference but its tedious and I want to learn how to do it in access because I foresee I have to do a lot of such multiple tables subtraction so its better I do this in access

Compare equal data between two tables with different formats?

Compare equal data between two tables with different formats? Icon
I had trouble naming the title for this thread, but here is my issue. I have two tables. Both contain the fields "LASTNAME", "FIRSTNAME", and "MIDNAME". I need to compare table1 to table2 to if a person is in both tables. This is needed because a company has their table and they receive an update of names so thus they need to compare their data. I'm having an issue because the updated excel file that i'm importing for the comparison sometimes uses a full middle name where the companies data only contains one letter for the middle name.

I currently have relationships between the three fields. I would like to be able to search equal between LASTNAME, FIRSTNAME, and 1st letter of MIDNAME. I don't know how to specify just the first character. So when working if one table has Mary A Roberts and the second has Mary Alice Roberts it will see them as being equal.

Compare Tables in Access

Compare Tables in Access Icon
I need to compare 2 tables with Same Structure in a Database and pull out records that are not matching in both the tables. As anyone done similar task in Access 2002, if so please let me know how this can be accomplised.