IF field evaluating a bookmark yields incorrect result

J

jo

I have a merge document with nested IF fields evaluating bookmarks.
The bookmarks are set at the beginning and ending of the document to
capture previous and current records for a directory merge. A
condensed version is as follows:

{ SET Place1 { MERGEFIELD VENDOR_NAME } { SET Place3 { MERGEFIELD
ITEM_NAME } }{SET Place5 {MERGEFIELD SWREPORTLABEL } { SET Place7
{ MERGEFIELD STD } }
{IF { Place2 } <> { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }
{IF { Place4 } <> { Place3 } "{ MERGEFIELD ITEM_NAME }" ""}
{IF { Place6 } <> { Place5 } "{ MERGEFIELD SWREPORTLABEL }" ""}
{IF { Place8 } <> { Place7 } "{ MERGEFIELD STD }" "" }
{MERGEFIELD BULLET_TEXT }
{ SET Place2 { MERGEFIELD VENDOR_NAME } { SET Place4 { MERGEFIELD
ITEM_NAME } }{SET Place6 {MERGEFIELD SWREPORTLABEL } { SET Place8
{ MERGEFIELD STD }}

At the level evaluating bookmarks Place8 and Place7, merged data is
incorrectly, but consistently for certain records, evaluated with the
true part of the IF statement (so there is no {MERGEFIELD STD}
repeated) when the bookmarked values are not equal.

Any ideas?
 
P

Peter Jamieson

Before doing anything else, can you please try quoting the bookmarks in the
IF statements (e.g.

change

{IF { Place2 } <> { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }

to

{ IF "{ Place2 }" <> "{ Place1 }" "{ MERGEFIELD VENDOR_NAME }" "" }
 
J

jo

Before doing anything else, can you please try quoting the bookmarks in the
IF statements (e.g.

change

{IF { Place2 } <> { Place1 } "{ MERGEFIELD VENDOR_NAME }" "" }

to

{ IF "{ Place2 }" <> "{ Place1 }" "{ MERGEFIELD VENDOR_NAME }" "" }

--
Peter Jamiesonhttp://tips.pjmsn.me.uk









- Show quoted text -

It worked; amazing, something so simple...thanks!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top