On 9 Aug 2005 at 10:08, Doug Thompson wrote:
...
> > I like OOo very much, don't get me wrong. But I get very frustrated 
> > with problems like this that have no good workaround.
> > 
> 
> You can create templates that can be reused each time you want to use 
> mail merge.  That way, you only have to go through all the fields one 
> time to set up conditional processing.
> 
> I assume you are aware that you can put more than one field in a line of 
> text.  The trick is to have your database fields properly normalized. 
> Then it is easy to include or exclude fields based on conditional 
> factors.  That will easily handle your concern about idiosyncratic UK 
> addresses.
> 
> I haven't the time and this isn't the proper forum for a dialogue on 
> data normalization, but even a minimal exposure to the concept will help 
> to resolve what you perceive as shortcomings in OOo and mail merge. 
> There are numerous tutorials available that can be found by a google 
> search on that two word phrase.

OK, I've had a chance to play around, after reading the document you 
suggested.  It does look as though OOo goes some way to doing this, but 
there do seem to be some problems - either something's not clear to me, 
or there are outright bugs.  Sorry if what follows is a bit lengthy.

What I'm doing is displaying my address book database (it's just a 
spreadsheet) above my experimental document.  The database has a field 
"Home Phone" which I'm playing with.  I type in "hp=", then drag the 
database column header down, and then type "=hp" (so I can see field 
starts and ends).

The text document now displays (I've got "view fields" enabled)
hp=<Addresses.Sheet1.Home Phone>=hp

I now swipe the cursor across all this to select it all, and hit 
control-F2 to get the Field Editor, and select Hidden Text. The Hidden 
Text box is prefilled with "hp=<Home Phone>=hp" (note loss of the path 
in the database). I drag the database column header down to the 
condition box, and prefix with "not " - the condition now reads
not [Addresses.Sheet1.Home Phone]
and click insert and close. I drag the "Home Phone" header onto a new 
line to see what happens without the condition.

The text area now shows (all highlighted as a field as field shadings 
is turned on)
Hidden text not [Addresses.Sheet1.Home Phone] hp=<Home Phone>=hp
Addresses.Sheet1.Home Phone

I then run this through the mail merge.

Here's the first hiccup - it's not possible to get everything into a 
single file - OOo insists on generating one file per database entry. 
But never mind, worse to come!.......

Now the files for those records with no home phone entry have two blank 
lines - that's fine. However those with a phone entry are incorrect. 
The second line is fine - it displays the correct phone number each 
time. But the first, conditional, line always displays the literal text
hp=<Home Phone>=hp

and I can find no way of getting the database entry substituted 
correctly. (I've tried editing the text in the Fields Editor box to no 
avail - I just get literal text every time). (Oh, I've also just found 
out about the "data to fields" button on the beamer - same result but a 
bit quicker :-)  )

In passing, if I try this with a template file instead of a plain 
writer file, OOo names all the resulting files as .stw instead of .sxw. 
:-(

Maybe I'm missing something, but could use more help please! Thanks.





-- 
various incoming sites blocked because of spam; see 
http://www.scottsonline.org.uk for a list and openpgp crypto key
(key fingerprint 2ACC 9F21 5103 F68C 7C32 9EA8 C949 81E1 31C9 1364)
[EMAIL PROTECTED]    Mike Scott, Harlow, Essex, England


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to