473,396 Members | 1,907 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Compressing update queries

My company receives a CD every month with US Gov. information about
imports and exports from the US. One of the things we have to do with
this before it is useable is to clean the data up. There are thousands
of Typos and inconsistencies in the raw data we get. At the moment I
probably have 300 or so individual update queries that take the form
similar to below:

UPDATE ImportsUnprocessed SET ImportsUnprocessed.Consignee = "SAMSUNG"
WHERE (((ImportsUnprocessed.Consignee) Like "*samsung*"));

We have about 1 field each time that need to be updated in each of
these different cases. Is there a way to compress this so I can run a
function with case statements or have a list of search criteria and
what to update it to?

There has to be an easier way!!! Please help

Nov 13 '05 #1
1 1274
Sudonim1234,
We dealt with something similar at a former employer of mine. We had a list
of standardized values for all the varients we were aware of. What we did
is maintain a table of these standardized values and joined it to our
recieved table. Before each run we would have to check the incoming data to
see if any new varients had appeared, add these to our table of standardized
values, then have a human validate the new rows, then make a new table with
the standardized values substituted for the varients.
You want to avoid changing the source data if at all possible. You also
want to implement a means by which the current batch run can be rolled back.
This way if the transform step screws up there is a way to restore the data
to the way it was before your process to import the data began. It is also
helpful to be able to show the client what changes are made so your process
can be audited and vetted.

"sudonim1234" <su*****@gmail.com> wrote in message
news:10*********************@k26g2000oda.googlegro ups.com...
My company receives a CD every month with US Gov. information about
imports and exports from the US. One of the things we have to do with
this before it is useable is to clean the data up. There are thousands
of Typos and inconsistencies in the raw data we get. At the moment I
probably have 300 or so individual update queries that take the form
similar to below:

UPDATE ImportsUnprocessed SET ImportsUnprocessed.Consignee = "SAMSUNG"
WHERE (((ImportsUnprocessed.Consignee) Like "*samsung*"));

We have about 1 field each time that need to be updated in each of
these different cases. Is there a way to compress this so I can run a
function with case statements or have a list of search criteria and
what to update it to?

There has to be an easier way!!! Please help

Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Yuancai \(Charlie\) Ye | last post by:
Hi, All: I am happy to annouce that we have formally released our latest SocketPro version 4 at www.udaparts.com, an advanced remoting framework written from batching/queue, asynchrony and...
17
by: kalamos | last post by:
This statement fails update ded_temp a set a.balance = (select sum(b.ln_amt) from ded_temp b where a.cust_no = b.cust_no and a.ded_type_cd = b.ded_type_cd and a.chk_no = b.chk_no group by...
9
by: Dom Boyce | last post by:
Hi First up, I am using MS Access 2002. I have a database which records analyst rating changes for a list of companies on a daily basis. Unfortunately, the database has been set up (by my...
1
by: Aaron | last post by:
Hello fellow programmers, I am trying to run an append/update query from code, a command button on a form initiates the queries. the format i am using is; ...
4
by: deko | last post by:
I'm a little nervous about slamming my database with a dozen Update queries in a loop that all modify RecordSources of open forms. Will the use of DoEvents and/or a Sleep function ameliorate any...
1
by: Grant McLean | last post by:
Hi First a simple question ... I have a table "access_log" that has foreign keys "app_id" and "app_user_id" that reference the "application_type" and "app_user" tables. When I insert into...
16
by: ARC | last post by:
Hello all, So I'm knee deep in this import utility program, and am coming up with all sorts of "gotcha's!". 1st off. On a "Find Duplicates Query", does anyone have a good solution for...
7
by: luciquar | last post by:
I am a PhD student in demography and I am working with a Microsoft Access database in which I have to use several update queries. Amongst these there are some in which I have to update the value of...
4
by: hapnendad | last post by:
In the question statement below Field names are in and variables are in (). All fields referenced are in what I have named the ‘PAR’ Table. Using MS Access 2003, I am working on a project...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.