Comparing And Replacing Data

Oct 17, 2006

Hi, I have 2 tables with similar data. However I need to compare this particular field called CompanyName in both tables. Reason being human error/exposition data errors. For example, Chef Kitchen Holdings Limited, in one table it is Chef Kitchen Holdings Ltd while the other table is Chef Kitchen Holdings Pte Limited, they both are the same but Access recognise them as 2 distinct datas.

Therefore I need help in comparing datas between these 2 tables for this particular field. So long as there is 75% similarities, one of the 2 tables will have the data replaced.

Is that possible using Access? if not, how about excel? please suggest.

thanks.

View Replies


ADVERTISEMENT

Replacing Data From A Backup Table

Sep 5, 2004

Hi, can anyone tell me how to replace the data in one table with data from a backup table? I've tried:

Insert into Customer
Select *
From CustomerBackup;

but I keep getting key violations.

View 1 Replies View Related

Comparing Data

Jan 31, 2005

Hi all.
I have a Quotation (Table), Quotation Details (Table), with One to many Relationship. Quotation Details(Table)
selects info from Products(Table). Then I have an Order (Table) connected with Quotation (Table) and Order Details
(Table) for ordering products.
What I want to do is to compare, when i make an order, the Quotation Details with the Order Details.
For example in a a quotation the customer is quoted with 4 piesces of modem. Then the next day he comes back with the
order but now he wants 3 modems. I would like to display a warning to the user or smt like that, inform him
that the quotation details are different from order details.
Is it possible??
Thank you in advance.

View 1 Replies View Related

Comparing Data

Dec 31, 2007

I have a database where I need to take the sum of all income and categorize it to find the commission rate according to what the sum is. For example, if the sum is between $0 and $7,500, the level is "A" and commission rate is 5%. If it's between $7500.01 and $15000, the level is "B" and commission rate is 4.5% and so on. I have this working with a switch() statement, and it finds the correct level exactly as I want it to.

Here's where I'm having a problem: if the sum of all income is $9,000, $7500 of that needs to be level "A" at 5% and the other $1500 needs to be "B" at 4.5%. How do I get that to split up?

Any suggestions would be appreciated.

Thanks.

View 1 Replies View Related

Comparing 2 Tables Of Data

Feb 28, 2007

Hi guys, i'll try and explain this as best i can....

I have 2 tables:

CurrentMonth
PreviousMonth

Both tables hold financial information by policy number. What i am doing is working out financial movement on a month on month basis. For example, if in previous month the financial position was £100 but in current month the finances had moved to £150 then the movement is £50 for the month. This i can do no problem by linking the tables by policy number and extracting the financial position and subtracting one from the other to give me a movement. However, in some instances there will be some policies that appeared in PreviousMonth but have since been cancelled back to policy inception so is not appearing in CurrentMonth.

Problem: I need to be able to bring in the policies on the previous month that are not appearing on the current month (due to cancellation).

Can anyone help me?

Cheers

View 1 Replies View Related

Comparing Data On Record At A Time

May 3, 2006

Hi - I'm working on a query, and can't seem to get it to work correctly. I have a table which contains 2 social security number fields - one for a dependent/employee with benefits, and one for the originally insured (for example, if an employee passed away, the dependent would be on the file, and the originally insured data would be populated with the original employees data). There are also cases where the employee and dependent exist in the table at the same time. I need to check the table, record by record, to identify any cases where the two SSN's are the same in any given record. The query is currently finding an employee's SSN on their record, and also finding it in the originally insured field of the dependent's record and showing it as an error. I only need to know if they occur for the same record, not for another record in the table. (I hope this makes sense!!!)

Is there any way that I can do this??? Any help would be greatly appreciated!!!!

View 4 Replies View Related

Modules & VBA :: Comparing Data In Two Tables

Jul 20, 2015

I have got 2 access tables named Table1 and Table2. There is one field common in both the tables and that is "Reference" . So I need to match the data in Reference field in both the tables using VBA.

steps to perform:

1. Check each Reference in Table1 against all the values in "Reference" field of Table2.

2. if match occurs then store all the details of that Reference in Table3.

There could be more than 1 match of that Reference in Table 2 and we need to check the whole Table2 for each "reference" value in "table1".

View 12 Replies View Related

Queries :: Comparing Data From One Field To Several Others

Aug 27, 2013

I have one table A that has a Name field that I would like to find if it matches any of the cases in table B with 2 other fields: Field 1 or Field 2

There is no way of establishing referential integrity because the Name Field can be found in either Field 1 or Field 2.

How would I go about searching so I can pull in the rest of the data that I need with when the Name is matched either with Field 1 or 2?

View 2 Replies View Related

Comparing Data In Text Box To A Prescribed Pattern

Jan 24, 2006

Hi all!

Got yet another question.

I have a text box field (txtLoanSN) for users to input serial numbers, but they can be of different formats depending on the type of service.

Examples are:
Type A - 020/2005, 001/2006
Type B - C2001/2006, C2006/2006
Type C - B1001/2005, B1021/2006

I would like to perform a series of actions based on the type of serial no. e.g. disabling another textbox (txtPNo) if txtLoanSN is like Type B or Type C.

How should the syntax for the If Statements be?

Would appreciate any help I can get!

Thanks!

View 9 Replies View Related

General :: Comparing Data From Multiple Tables

Nov 5, 2013

We have an "item" table that contains information specific to an item (the item number is unique); and multiple "production line" tables. There is a relationship between the Items table and the Production Line tables (all 8 of them). Each item can be entered on 1 or more production line tables because one item may be produced on multiple lines and the settings vary based on the line they're produced. When entering an item in the Production table we MUST make a selection from the Item table.

Now, what I want to do is identify which item number(s) from the Items table does not have a specific field entry in ANY of the Production Line tables.

View 9 Replies View Related

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

Comparing Data From Two Tables And Appending Into 3rd Table

Dec 8, 2012

I have 2 tables as below

Table 1
ID RID StartM EndM
1 xyz 1100 040.0935 040.1254
2 xyz 1100 029.0110 038.1003
3 xyz 1100 029.0110 038.1010

Table 2RID
StartM
EndM

[code]...

Now I need to create 3rd table based on above two tables

for table1.XYZ 1100 table1.StartM>Table2.StartM then table1.ID=2or 3 and
for table1.xyz 1100 table1.EndM< Table2.EndM then table1.ID=1

View 5 Replies View Related

Queries :: Comparing Data From Current To Previous Years

Oct 9, 2013

I have a table which is used to record electric billing period dates, total kWh and costs for a list of locations each month. I would like to compare the quarter total kWh and costs for this year "2013" against same quarter last year "2012". I have created two queries, the 1st is capturing data from 2013 and the 2nd is capturing data from 2012. I created a 3rd query which joins the 1st and 2nd together by month where fields match. Both tables have the same fields, however there is more records in 2012 than 2013. How can I join the tables together so months that have no data are left blank?

View 14 Replies View Related

Queries :: Comparing Data Differences Between Two Identical Access Tables?

Dec 10, 2013

I have two identical Access tables, for example tblDataYesterday and tblDataToday. The data from tblDataToday has updated data changes in it that are different from tblDataYesterday. I have a maximum of 100 fields to review. I want to compare the two tables and display in a query the differences between the data from both tables.

View 1 Replies View Related

Comparing Data Entered Daily With Data Entered Monthly?

Jul 30, 2012

I am fairly new to access but so far I have been able to get what i need from it, until now. I am trying to find a way of comparing two sets of data to find out an employee's average productivty.

Table 1 -Hours Worked (by day)
- contains 'name' 'date' and '# of hours' worked
- an employee would enter the hours here on a daily basis

Table 2 - Contracts Keyed (by month)
- contains the number of contracts worked that is derived from seperate system
- this is entered on a monthly basis (so for example: John keyed 30 contracts for the month of January)
- the system i am pulling this info from does not have the ability to pull a daily count of contract per employee, only a range of dates and it then provides the sum for that range (unless I ran a query for each day, for each employee which would take me hours)
- employees dont have access to this system to enter their own # of contracts keyed on a daily basis.
- for entry, so far i have just been putting the first of the month and then the # of contracts.

In a nutshell, this is the calculation I am trying to create:

(Sum of "# of hours" for the month) / (total "# of contracts keyed" for the month) = employees average hourly productivity.

I have tried to do this with various types of queries and reports but with no luck, I get a prompt saying that access can't compare the 2 fields.

Is there a way to compare the data that is entered daily with the data i would enter monthly?

View 2 Replies View Related

Replacing Many Iif By Something Better

Jun 21, 2007

I have a customer who made a query with a field that looks like that:

NewField: iif(Field1=True and Field2>100 and isnull(Field3);"Blue";iif(Field1=True and Field2>100 and not isnull(Field3);"Black";iif(Field1=True and Field2=100 and isnull(Field3);"White";... And so on, for miles and miles.

Although it works, and fast enough, I don't like the way it is displayed and I am sure that it could be even faster without all these iif.

Any idea about the best way for me to handle this kind of query?
Thanks!

View 2 Replies View Related

Replacing 'Name' With 'ID' Taken From Another Table

Dec 19, 2007

I have a main table which contains data on Oilfields. This is set up with an auto number for ID and a name of each oil field. I have other tables which contain things such as Pipelines, Wells and Platforms, which are linked back the the main table.

The problem is that the database was given to me with the links being between the Oilfield_Name, and not using the Oilfield_ID (which is not present in the 'satellite' tables). How can i add the oilfield_ID column to the 'satellite' tables so i can link them properly?! (i can obvioulsy physically add an 'Oilfield_ID' column to the 'satellite field', but how do i populate it with all the correct IDs from the main table, to suit what is in the 'Name' column of the 'satellite' field- does that make sense?). I suppose I need to replace all of the Names with the IDs?

This has been giving me such a headache. The Oilfields table has 2500ish records, with as many as 1200 in the other tables linked to it.

View 7 Replies View Related

Replacing Query

May 16, 2007

hi. i are replacing queries in my tables to get the database ready to convert to SQLServer.
Am having a problem replacing a query that is brings in a table for a drop down and inserting the selection in the record.
during creation, the record shows a date, id, task, hours.
the datatable needs date, id, task_code, task_name, task_job, hours.
On "task" the drop-down allows for selection of several choices that are 3 columns wide. i can get the columns to show but only the first column currently goes in my new table. the table's columns that the selection comes from is "task_code,task_name, task_job". All columns are needed as different areas use the same task code but use different jobs or names.

I was told to use a insert into statement, however am having problems with it.

have as follows:
SQLStatement = "SELECT [Task_code], [Job_name], [Task_name] FROM tablea; "
rec.Open SQLStatement, , adOpenDynamic

job = rec(1)
task = rec(2)

rec.Close

SQLStatement = " Insert into [tableb]([Job_name],[Task_name]) " & _
" values (" & job & ", " & task & " ) "

rec2.Open SQLStatement, , adOpenDynamic

db.Execute (SQLStatement)

any point in the right direction would be greatly appreciated.

thanks,
slh

View 1 Replies View Related

Replacing Most Recent Record

Dec 11, 2007

Hi, Im building a DB that basically tracks the hours people have worked,
its all going fine apart from one major bug which i cant get my head around, I am trying to work out a way so that if someone decides to change the hours they have worked it replaces the existing record and does not create a new record.

Each record has a unique user ID attached and each day is dated, do you think this is a VBA solution or a change in the relationships perhaps?

Sorry fi there is already a similar answer to this question on the forum, but i couldnt find one!:confused:

Thanks in advance,

Paul

View 2 Replies View Related

Replacing Cell Value In A Table

Aug 1, 2007

OK, here is my situation. I have an access database which is updated automatically every night with new data. My companies solution to this is each morning, the entire database is downloaded to my computer to be used by another application.

In one of the tables, there is a field that doesn't work for my purposes, so each day I have to manually open the table, and change the contents of that field for every record. For example, lets say I have the following table:

Field1 Field2 Field3 Field4
Rec1 Wigets Faucet Model1A
Rec2 Wigets Faucet Model1B
Rec3 Wigets Sink Model1A
Rec4 Wigets Sink Model1B
Rec5 Wigets Toilet Model1A

Each day I manually change Field2 so it reads "Total" and whatever is in Field2:

Field1 Field2 Field3 Field4
Rec1 Total Faucets Faucet Model1A
Rec2 Total Faucets Faucet Model1B
Rec3 Total Sinks Sink Model1A
Rec4 Total Sinks Sink Model1B
Rec5 Total Toilets Toilet Model1A

Each morning when I receive the new database download, they all go back to widgets.

Is there a macro or module I can create to automatically look at Field3, and then assign a new value to Field2 based on Field3's value?

Any help would be appreciated!!!!

View 3 Replies View Related

Replacing Special Characters

Feb 20, 2007

I am exporting an Access table as an xml file and need to be able to identify and replace '&', '(' and ')' as they are not accepted in xml.

Does anyone know how a query can be built which will find these characters in fields and update to ' and' or just remove?


Thanks

View 1 Replies View Related

Queries :: Replacing Null With Zero

Sep 15, 2014

I am having a query, where a few date records are null because of no entry or record, what a want that the field with no date entry to be come up with zero "0" .

View 1 Replies View Related

Comparing Data In One Column To Another Column

Jun 20, 2006

I have two separate columns in my query but they contain the same kind of data. These two columns data should match but some of the data doesn't. Can I write a criteria that will show me only the rows that do not match.

DUTYPOSC
11B111B1
11B111B1
11C111B1
11B111B1
92Y111B1
11B111B1
13F121B1
For example, I want the query to show me only the rows in which the data in the Duty column doesn't match the POSC column.

View 1 Replies View Related

Replacing Repeated Values From Recrods?

Mar 4, 2007

Attaching a sample mdb file. I have TABLE1, TABLE2 and QUERY1, QUERY2 in my mdb file.

I want Query1 Value 4 once in Query2. It should not be repeated again with [SBNO] values 5 time.

Value 4 in Query 2 shows with only 1st record and remaing 5 records shows 0 value instead of 4.

How is it possible.? Can anyone help me.

View 3 Replies View Related

Replacing Numbers With Their Text Meaning

Aug 19, 2004

I created a database that has a field called "Corrective Actions." I want the user to be able to type in a series of numbers, in the following format: 001, 002, 051, 123. Each number has a certain meaning. For example, 001 means "Upgrade to current revision," 002 means "Replace Unit," and so on. Here is what I would like to happen: The user will type in the numbers in the appropriate format. When the user presses the tab key to go to the next field, I want the numbers to be replaced with the actual meaning. My problem is that I can not figure out how to accomplish this. Can anyone help me?

View 5 Replies View Related

Replacing Spaces With %20 For Mailto Link

Aug 29, 2005

Hi. I have a database which store the subject title of the mailto link using the upload form. I would like to construct a mailto link that picks up the suject title from my database. However, there are spaces in the subject and the mailto link cuts off at the first spacing. In my display page, I would like to replace the spaces with %20 but have had no success with any attempts.

This is the code that add the data to the database

rs.AddNew
rs("File Name") = fileName
rs("File Size") = fileSize
rs("File Data").AppendChunk fileData
rs("Content Type") = contentType
rs("Title") = "<td valign=top><table width=100% border=0 cellspacing=3 cellpadding=0><tr><td valign=top bgcolor=#a1be1e><font color =white><span class=mainNav4 style5>" & Title & " </span><span class=bodyC2 style5> </span></font color></tr>"
rs("Text") = "<tr><td valign=top><span class=bodyC2>" & Text & " </span>"
rs("Price") = "</span> <span class=style6><strong><font color=#FF6600> " & Price & "**each</font></strong></span>"
rs("Note") = "<br><span class=style6><em><font color=#a1be1e> Note:** " & Note & " </font></em></span><span class=bodyC2></span></td></tr>"
rs("Button") = "<tr><td><br><a href=mailto:GM@acx.com.sg?subject=" & Button & " class=outlinerCen>&nbsp;Enquire&nbsp;</a><br><br></td></tr></table></td></tr><tr><td colspan=2 valign=top><span class=dottttt>.................................................. .................................................. ...</span></td></tr></table><br>"


And this is to display

If NOT rs.EOF Then

Response.Write "<body><table width=350 border=0 cellpadding=0 cellspacing=5><tr><td width=5 valign=top><table border=0 cellpadding=0 cellspacing=0 class=outlinerProducts><tr><br><td><img src=""file.asp?ID=" & rs("Id") & """width=130 height=130></td></tr></table></td>"
Response.Write rs ("Title") & "<br>"
Response.Write rs ("Text") & "<br>"
Response.Write rs ("Price") & "<br>"
Response.Write rs ("Note") & "<br>"
Response.Write rs ("Button") & "<br>"

rs.MoveNext


end if

Some assistance would be appreciated. Thank you.


Wolf

View 4 Replies View Related







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