# Thread: Mailmerge with 3 if conditions not working why Pls Help!!

1. ## Mailmerge with 3 if conditions not working why Pls Help!!

Hi all,
I am baffled why my simple if statement is not working.

I started off with a simple if statement of:
(if the field RHYMES = book, then list the text "the quick brown fox. if the field RHYMES = song then list the text "jack and Jill"

{IF {MERGEFIELD RHYMES} = "Book" "The quick brown fox" {IF {MERGEFIELD RHYMES} = "Song" "Jack and Jill"

I then need to add a 3rd condition and found that I could not use the word "and", this is where my problem started, as bringing in the 3rd condition stops my mail merge working.

{IF {MERGEFIELD RHYMES} = "Book" "The quick brown fox" {IF {MERGEFIELD RHYMES} = "Poem" "The quick brown fox" {IF {MERGEFIELD RHYMES} = "Song" "Jack and Jill"
(what I want here is if the field rhymes =book show text The quick brown fox and also if the rhymes field is = Poem show the text The quick brown fox, but if the rhymes field is =song, show the Text Jack and Jill.

what could I be doing wrong?

If someone could help I await your replies

Thank You

2. I don't see any end to your fields.
Try three separate IF Fields:
{IF {MERGEFIELD RHYMES} = "Book" "The quick brown fox"}{IF {MERGEFIELD RHYMES} = "Poem" "The quick brown fox"}{IF {MERGEFIELD RHYMES} = "Song" "Jack and Jill"}

3. ## The Following User Says Thank You to Charles Kenyon For This Useful Post:

mariejoe (2013-07-07)

4. Hi Charles, thanks for the answer.

Your solution is one thing I had in mind of writing the statement it's just that above I have summarised the text to a few words in reality my text is about 500 words to fit into a small table box and I wondered if there was a short cut to avoid having to repeat the 500 words for each scenario, which also may in the future grow. Is there a way that something like "And" can be used to cover 3 different conditions so I only have to write the 500 word text once? an d if so how could I write this please.

Any help would be truly appreciated

Regards Mariejoe

5. Long term, look into AutoText and Building Blocks. Short term, look into bookmarks and REF fields.