PC Review


Reply
Thread Tools Rate Thread

3 csv file to one & linking to find unique rows

 
 
steve1040
Guest
Posts: n/a
 
      7th Sep 2010
All
I have 3 csv files

File1
(Row1=Column header)
Field1 = Year
Field2 = Location
Field3 = Dept
Field4 = Month
Field5 = 1total
Field6 = 2total

File2
(Row1=Column header)
Field1 = Year
Field2 = Location
Field3 = Dept
Field4 = Month
Field5 = 3total


File3
(Row1=Column header)
Field1 = Year
Field2 = Location
Field3 = Dept
Field4 = Month
Field5 = 4total

I would like to output a single file
If
File1.field1=File2.field1 & File2.field1=File3.field1
File1.field2=File2.field2 & File2.field2=File3.field2
File1.field3=File2.field3 & File2.field3=File3.field3
File1.field4=File2.field4 & File2.field4=File3.field4

I guess another approach would be to concatenate the first 4 columns
in each file and then see if the row matches.


then write to new csv output file
(Header Row1=Year,Location,Dept,month)
File1.Field1 = Year
File1.Field2 = Location
File1.Field3 = Dept
File1.Field4 = Month
Field5 = 1total
Field6 = 2total
Field7 = 3total
Field8 = 4total

I hope this makes sense

Thanks
Steve
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to convert duplicate rows into unique rows in a Table? KK Microsoft Access Queries 2 7th May 2008 02:40 PM
Imported text file w/o unique identifiers, find duplicates jeremiah Microsoft Access Queries 3 9th Jan 2008 05:12 PM
Linking to an Excel file : how to find the actual last row ? Michel S. Microsoft Access 2 28th Jul 2006 07:36 PM
find rows for unique data in 1 column and different data in other. =?Utf-8?B?RG90IE1hamV3c2tp?= Microsoft Excel Misc 1 21st Jan 2005 12:23 AM
How do I find the unique words in a large Word 2003 file? =?Utf-8?B?UGFjUmltIEppbQ==?= Microsoft Word Document Management 1 16th Oct 2004 07:03 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:16 PM.