Cleaning up data
From: Munch (Munch_at_discussions.microsoft.com)
Date: 11/26/04
- Next message: Paul Pedersen: "Re: Column Order in Table"
- Previous message: Peter Newman: "Backup Maintinance"
- Next in thread: John Bell: "Re: Cleaning up data"
- Reply: John Bell: "Re: Cleaning up data"
- Reply: Hugo Kornelis: "Re: Cleaning up data"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 26 Nov 2004 12:05:04 -0800
Here is some sample data.
ID INITIAL NAME SEX HIREDATE STATDATE STA ACT REA ENDDATE
123456 AA SMITH M 19680513 19680513
123456 AA SMITH M 19680513 20030115 A
123456 AA SMITH M 19680513 20030215 A
123456 AA SMITH M 19680513 20030315 A
123456 AA SMITH M 19680513 20030415 A
123456 AA SMITH M 19680513 20030510 A
123456 AA SMITH M 19680513 20030615 A
123456 AA SMITH M 19680513 20030715 A
123456 AA SMITH M 19680513 20030815 A
123456 AA SMITH M 19680513 20030915 A
123456 AA SMITH M 19680513 20031015 A
123456 AA SMITH M 19680513 20031118 A
123456 AA SMITH M 19680513 20031214 A
123456 AA SMITH M 19680513 20040118 A
123456 AA SMITH M 19680513 20040215 A
123456 AA SMITH M 19680513 20040328 P PLA MED
123456 AA SMITH M 19680513 20040411 P PLA MED
123456 AA SMITH M 19680513 20040516 P PLA MED
123456 AA SMITH M 19680513 20040620 P STD MED
123456 AA SMITH M 19680513 20040718 P STD MED
123456 AA SMITH M 19680513 20040819 P STD MED
123456 AA SMITH M 19680513 20040915 P STD DIS
123456 AA SMITH M 19680513 20041017 X
I need to clean the data in this table up to make it look like a history
table. I want to only have unique records in the table so that the table
reads as such
ID INITIAL NAME SEX HIREDATE STATDATE STA ACT REA ENDDATE
123456 AA SMITH M 19680513 19680513 20030115
123456 AA SMITH M 19680513 20030115 A 20040328
123456 AA SMITH M 19680513 20040328 P PLA MED 20040516
123456 AA SMITH M 19680513 20040620 P STD MED 20040819
123456 AA SMITH M 19680513 20040915 P STD DIS 20041017
123456 AA SMITH M 19680513 20041017 X
there are some other abnomalities in the source data aswell. There are
cases where the hire date is not consistant or can be null or zero filled.
For example:
ID INITIAL NAME SEX HIREDATE STATDATE STA ACT REA ENDDATE
123456 AA SMITH M 19680513 19680513
123456 AA SMITH M 19680614 20030115 A
123456 AA SMITH M 19680715 20030215 A
123456 AA SMITH M 20030315 A
123456 AA SMITH M 19680917 00000000 A
123456 AA SMITH M 00000000 20030510 A
Thanks for any help on trying to fix this terrible data.
- Next message: Paul Pedersen: "Re: Column Order in Table"
- Previous message: Peter Newman: "Backup Maintinance"
- Next in thread: John Bell: "Re: Cleaning up data"
- Reply: John Bell: "Re: Cleaning up data"
- Reply: Hugo Kornelis: "Re: Cleaning up data"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|