5 Replies Latest reply on Aug 16, 2011 10:40 PM by John Hawkinson

    Strange Behavior with Data Merge (CS4) - Advice?


      This is the most bizarre behavior and I may have to chalk it up to a full moon or something since I can't reproduce it and I cannot find any hints as why this happened. This is my last attempt at figuring a solution...maybe someone has experienced this??? Anyway, here's what happened...


      I do a data merge for addressing envelopes. Been using the InDesign data merge feature for a couple of years now, no problems.

      My address list is approximately 1200. It's in a .csv file with the following fields: fname, lname, company, address1, address2, city, state, zip


      For my last mailing, approximately 300 addresses were merged wrong. Here's the crazy thing it did: instead of using the address1 field for the current record, it used the address1 field from the NEXT record, and ONLY the address1 field.

      Here's more bizarre-ness. The NEXT record was merged correctly.

      For example:

      Record 1 (address1 should be 555 Cherry Lane, Apt 5)

      John Smith

      Smith Company

      123 Main Street, Apt 5

      Small Town, CA 12345


      Record 2 (John Smith's address used THIS address1, but NOT address2 or any other field! Jane Doe's address is correct)

      Jane Doe

      Doe Company

      123 Main Street, Suite 300

      Big Town, TX 56789


      I've tested. I've looked for commonality in the records, where it's placed, if there was something unusual about it's format. I come up empty. The incorrect data seem randomly interspersed.


      One thing that I have to do is break up the actual merge. Either my computer memory or InDesign can't handle 1200 merge records. So, I merge approximately 200 records at a time (I make 6 print files). I don't know if this has anything to do with it (like I said, the incorrect data is interspersed all through out), but, thought I'd mention it.


      Any advice is appreciated. I'm hesitant to use it again until I can understand why this happened.


      thanks much,


        • 1. Re: Strange Behavior with Data Merge (CS4) - Advice?
          Peter Spier Most Valuable Participant (Moderator)

          CS was soemtimes flakey in this way with Data Merge.

          Are you updated to the latest patch? Most issues were resolved at some point.


          That said, I recall another user with this problem, and it never resolved with his particular file. I examined the data file and couldn't find any issues, but it behaved identically on my system tot he way it did on his so I can only conclude there was still some bug, or something about the data file that we were unable to detect. I seem to recall that the same data file merged correctly in CS3, but I don't recall if I saved it long enough to test in CS5. I've not had any issues with my own files in any version.


          Open the file in a plain text editor and look for any odd characters (I'd start the search where the merge first fails). Also do a Save As from the text editor to make sure there is no possibility of formatting from your spread sheet having found its way in.

          1 person found this helpful
          • 2. Re: Strange Behavior with Data Merge (CS4) - Advice?
            zinegraphics Level 1

            Thanks, Peter. I'm up to CS5.5 now, but I haven't used the data merge feature with it yet. Even in CS4, I couldn't reproduce the problem.


            As far as odd characters, the address1 field sometimes has double quotes around it when there is a comma in the field. But, again, it's not consistent for all the records that were merged incorrectly. There doesn't appear to be any spaces or weird paragraph breaks.


            In any case, it sounds like some bugginess since you were able to reproduce it. I can't reproduce it. It's impossible to verify the data merge is correct (too much data!) so I may have to think of another solution for my variable data needs. Got in big trouble with my client because of this!

            • 3. Re: Strange Behavior with Data Merge (CS4) - Advice?
              John Hawkinson Level 5

              I would inspect the CSV file very carefully, perhaps in a hex editor. There may be nonprintable characters that are causing this problem.

              Also, is it possible that you have an odd number of double-quotes somewhere right before this problem?

              • 4. Re: Strange Behavior with Data Merge (CS4) - Advice?
                Colin Flashman Adobe Community Professional

                as john said, could be non-printing characters, but i'd suspect there was a comma in an address in the database somewhere, which has "fooled" indesign into thinking there is a field where there shouldn't be one.


                rather than use csv, i tend to use a tab-delimited txt file from excel so that i can include commas in the database.


                that's about all i could think of.

                • 5. Re: Strange Behavior with Data Merge (CS4) - Advice?
                  John Hawkinson Level 5

                  Sort of damned-if-you-do, damned-if-you-don't. If you use tab-delimited,

                  then you can't have tabs. If you use CSV, you can have commas as long as

                  they are on double-quotes. But you can't have double-quotes. Etc. etc.