I am having trouble figuring this one out... Hopefully someone can
help!
I have a table ("tbl1")
It has five (5) fields:
1- "Item1"
2- "Item2"
3- "Item3"
4- "ScanImage" (stores scan path/filename)
5- "ID"
I can have an "order" with up to three Items. We scan the order and
create a "ScanImage" filename (row). In the past each order that had
multiple "Items" was "Cloned" and a duplicate "ScanImage" record was
created.
A sample of two orders with three items on each:
Item1 Item2 Item3 ScanImage ID
x1 scan1 1
y1 scan1 2
z1 scan1 3
a1 scan2 4
b1 scan2 5
c1 scan2 6
What I need to do is turn these six (6) records into two (2) by
populating the "Item2" and "Item3" fields using the "ScanImage" as the
unique id.
So the set should look like this:
Item1 Item2 Item3 ScanImage
x1 y1 z1 scan1
a1 b1 c1 scan2
I know this is not an ideal schema (far from it) but I am required to
report the data in this format. I am trying to do this after the fact
(last year's data which was not keyed in correctly).
There are over 3000 individual records that need this "cleansing".
Thanks to all in advance.
-Bob