<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
     xmlns:admin="http://webns.net/mvcb/"
     xmlns:content="http://purl.org/rss/1.0/modules/content/"
     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
	<channel> 

	<title>Comments on: Eventually, all things merge into one, and a river runs through it.</title>
	<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it/</link>
	<description>Comments on Ask MetaFilter post Eventually, all things merge into one, and a river runs through it.</description>
	<pubDate>Thu, 06 Apr 2006 16:54:11 -0800</pubDate>
	<lastBuildDate>Thu, 06 Apr 2006 16:54:11 -0800</lastBuildDate>
	<language>en-us</language>
	<docs>http://blogs.law.harvard.edu/tech/rss</docs>
	<ttl>60</ttl>

	<item>
		<title>Question: &quot;Eventually, all things merge into one, and a river runs through it.&quot;</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it</link>	
		<description>Complex Excel to Word merge question is the  &lt;br /&gt;&lt;br /&gt; Its going to be difficult to explain this clearly, so bear with me.&lt;br&gt;
&lt;br&gt;
I have two Excel files I need to merge into one (long) Word document.&lt;br&gt;
&lt;br&gt;
The first file is a straightforward merge:  Names and addresses and such.  Each one of these (lets call them the Customer Records) are tagged with a specific, unique, numeric ID.  There are 400+ customer records.&lt;br&gt;
&lt;br&gt;
The second file is more complex:  It is a list of purchases made by the customers.  Some customers have made dozens of purchases, some only one or two.  Each customer purchase has the unique customer record ID attached, plus other information.  There are 3000+ purchase records for these 400+ customer records.&lt;br&gt;
&lt;br&gt;
The output that I want is:&lt;br&gt;
A single customer&apos;s contact information and buying  history on a single word document page, then a page break, the next customer, and so on for 400+ pages.&lt;br&gt;
&lt;br&gt;
So imagine&lt;br&gt;
&lt;br&gt;
customer ID&lt;br&gt;
Name&lt;br&gt;
Address&lt;br&gt;
email&lt;br&gt;
telephone&lt;br&gt;
comment&lt;br&gt;
&lt;br&gt;
purchase 1 data (date, amount, product)&lt;br&gt;
purchase 2 data (date, amount, prodcut)&lt;br&gt;
purchase 3 data (date, amount, product)&lt;br&gt;
&lt;br&gt;
[page break]&lt;br&gt;
&lt;br&gt;
Next customer record&lt;br&gt;
&lt;br&gt;
... and so on -- but remember that some customers have 20+ purchases and some have only one.&lt;br&gt;
&lt;br&gt;
I&apos;m all good with the Name, address, merge part -- the part that is stumping me getting only the purchase data that is tied to that specific cusomer ID on the page I want it.&lt;br&gt;
&lt;br&gt;
Is there some way within the Word Merge function to tie the Customer ID in the name/address record to the Customer IDs listed in the purchase record, so that only the customer purchases that are tied to that customer ID appear on each page?  In a database program I would do this by creating a form with a repeating pannel, but that isn&apos;t an option here.&lt;br&gt;
&lt;br&gt;
My predecessor in this job, who was largely incompetent in may respects, managed to create an output like this, and I am taking a &lt;i&gt;lot&lt;/i&gt; of abuse for not being able to replicate her results.  Unfortunately, I only have hard copy of her output, not any electronic copy I can reverse engineer.&lt;br&gt;
&lt;br&gt;
Its possible that she did the whole thing by hand, as a copy/paste back and forth from Word to Excell and back again, but the sales director swears that &quot;she just pressed a button&quot; and it all merged together.&lt;br&gt;
&lt;br&gt;
I can change the Excel to .txt or .dbf or other formats if I need to, but the output &lt;i&gt;must&lt;/i&gt; be in a Word document.&lt;br&gt;
&lt;br&gt;
I&apos;m going to a meeting, but will reply to any questions in a few hours when I return.&lt;br&gt;
&lt;br&gt;
Thanks for your help!</description>
		<guid isPermaLink="false">post:ask.metafilter.com,2006:site.35865</guid>
		<pubDate>Thu, 06 Apr 2006 15:32:40 -0800</pubDate>
		<dc:creator>anastasiav</dc:creator>
		
			<category>Word</category>
		
			<category>Excel</category>
		
			<category>Merge</category>
		
	</item> <item>
		<title>By: pompomtom</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557565</link>	
		<description>I have done something similar to this before by working out the maximum number of (in this case) purchases per customer, and having that many fields for purchases in the merge doc. Then ensure those fields are set to &quot;Skip field if blank&quot;.&lt;br&gt;
&lt;br&gt;
You would then need to lay out your data source so each row is like Name, Address etc, Purchase1_field1, Purchase1_field2 ... Purchase1_fieldn, Purchase2_field1, etc. This may be a pig, but you may be able to do a lot of it with a few paste-special-transposes.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557565</guid>
		<pubDate>Thu, 06 Apr 2006 16:54:11 -0800</pubDate>
		<dc:creator>pompomtom</dc:creator>
	</item><item>
		<title>By: escher</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557568</link>	
		<description>As far as i know, there is no built-in way for microsoft word to handle two different data sources - you&apos;ll have to put all the data in one table. There are two things you&apos;re going to have to do to make this work:&lt;br&gt;
&lt;br&gt;
1) Combine the data somehow. I don&apos;t know how to do this in excel but i know how to do it in access. I can help you out with this if you like. You want it to be one big table with all the data, with columns like:&lt;br&gt;
&lt;br&gt;
customerID, customerName, orderNumber, amount&lt;br&gt;
&lt;br&gt;
basically, you&apos;re just adding a few columns onto the &quot;purchases&quot; table: one for the customer name, one for address and such. There will be lots of redundant data, but that&apos;s okay.&lt;br&gt;
&lt;br&gt;
2) Use the following method to break it up for one customer on each page with multiple purchases.&lt;br&gt;
&lt;br&gt;
http://support.microsoft.com/?kbid=211303&lt;br&gt;
&lt;br&gt;
Hope it helps.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557568</guid>
		<pubDate>Thu, 06 Apr 2006 16:58:31 -0800</pubDate>
		<dc:creator>escher</dc:creator>
	</item><item>
		<title>By: AmbroseChapel</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557569</link>	
		<description>It definitely sounds like the kind of thing you can do with the Data Merge Manager which has a bewildering number of options and buttons. &lt;br&gt;
&lt;br&gt;
Just experimenting, I&apos;ve got Word&apos;s merge features to open an excel spreadsheet and using &quot;Query Option&quot; to say it should merge only the data where &quot;customer number&quot; is equal to 1, for instance, so the only missing piece is getting it to match, not a hard-coded 1, but a value from the other sheet.&lt;br&gt;
&lt;br&gt;
Alternative approach -- who was your predecessor&apos;s pal at the company? It sounds like someone with more skills than her set the thing up for her. Find that person and ask them how it&apos;s done?</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557569</guid>
		<pubDate>Thu, 06 Apr 2006 17:00:59 -0800</pubDate>
		<dc:creator>AmbroseChapel</dc:creator>
	</item><item>
		<title>By: AmbroseChapel</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557570</link>	
		<description>Didn&apos;t preview. Maybe it&apos;s not possible. Sorry to have misled you.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557570</guid>
		<pubDate>Thu, 06 Apr 2006 17:02:28 -0800</pubDate>
		<dc:creator>AmbroseChapel</dc:creator>
	</item><item>
		<title>By: kaytrem</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557582</link>	
		<description>Here&apos;s what I would do: import the two data files into one MS Access file (.mdb) as two tables &apos;customers&apos; and &apos;purchases&apos;.  Set the customerID in the &apos;customers&apos; table as the primary key for that table.  Let Access add a primary key to the &apos;purchases&apos; table.  Go into Tools|Relationships and add both tables.  Click the customerID field in the &apos;customers&apos; table and drag it over to the customerID in the &apos;purchases&apos; table to create a &apos;one to many&apos; relationship.  Save and close the relationships tool.  Play with the Reports wizard to see if you can use one of the standard reports to do produce the look you want. Once you get a report in Access working you should be able to convert it to word using a button in the Tools menu that says &apos;Report this in MS Word&apos; or somesuch.  I&apos;m doing this off the top of my head and I totally hope I didn&apos;t miss something in reading your situation description.  If I heard you right though, this is the way to get the job done.&lt;br&gt;
&lt;br&gt;
Good luck.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557582</guid>
		<pubDate>Thu, 06 Apr 2006 17:21:32 -0800</pubDate>
		<dc:creator>kaytrem</dc:creator>
	</item><item>
		<title>By: beelzbubba</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557585</link>	
		<description>kaytrem&apos;s solution is the one I had in mind. It should work.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557585</guid>
		<pubDate>Thu, 06 Apr 2006 17:25:57 -0800</pubDate>
		<dc:creator>beelzbubba</dc:creator>
	</item><item>
		<title>By: jasper411</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557716</link>	
		<description>What kaytrem said, definitely! This is *easily* done in Access, and that&apos;s the place that distributed data like yours should reside anyway, not in a flat file setup like Excel.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557716</guid>
		<pubDate>Thu, 06 Apr 2006 21:04:19 -0800</pubDate>
		<dc:creator>jasper411</dc:creator>
	</item><item>
		<title>By: willnot</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557757</link>	
		<description>I would use the VLOOKUP function in excel to add the data from your first sheet to your second sheet. I would then use pivot tables to get a summary list by client. I&apos;m generally pretty happy just having the data in Pivot tables, but it should be pretty easy to break that out into a way that you can import it easily into Word.&lt;br&gt;
&lt;br&gt;
People tend to be really confused by VLOOKUP and Pivot tables, but once you get the hang of them, they&apos;re crazy simple and very powerful for this kind of thing.&lt;br&gt;
&lt;br&gt;
I&apos;m sure you can find a good help file for using this stuff with a Google search, but let me know if you need a walk through.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557757</guid>
		<pubDate>Thu, 06 Apr 2006 22:27:31 -0800</pubDate>
		<dc:creator>willnot</dc:creator>
	</item><item>
		<title>By: Lanark</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557818</link>	
		<description>Access is the tool for this job, if you want to keep the data in Excel you can Link/Attach the two spreadsheets and work with them in Access.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557818</guid>
		<pubDate>Fri, 07 Apr 2006 03:23:31 -0800</pubDate>
		<dc:creator>Lanark</dc:creator>
	</item><item>
		<title>By: Sprout the Vulgarian</title>
		<link>http://ask.metafilter.com/35865/Eventually-all-things-merge-into-one-and-a-river-runs-through-it#557887</link>	
		<description>I&apos;m so sorry to say it, but Access is going to do this for you.  It&apos;s kind of a b*tch of a program to learn, but you probably DO have it on your computer somewhere, and you can &apos;Import&apos; your existing spreadsheets into a new database.&lt;br&gt;
&lt;br&gt;
It *will* take a while to learn how to set things up in Access, but once you do, you&apos;ll look like a wizard with all the stuff you&apos;ll be able to produce.  The &apos;Report&apos; that you make can easily be Exported to Word.&lt;br&gt;
&lt;br&gt;
I suggest that if you choose to attempt Access, start with a Template database.  I think the &quot;Order Entry&quot; one will work for you.</description>
		<guid isPermaLink="false">comment:ask.metafilter.com,2006:site.35865-557887</guid>
		<pubDate>Fri, 07 Apr 2006 06:57:53 -0800</pubDate>
		<dc:creator>Sprout the Vulgarian</dc:creator>
	</item>
	</channel>
</rss>
