0

I am trying to make an IF statement with two condition like this:

 %%[ 
 SET @PACKAGE_rows = Lookuporderedrows("TABLE","10","ORDER
 DESC","CRITERIA","True")  
 SET @USER_REGION_ID =
 lookup("CONTACTS","region_id","email",@USER_EMAIL) IF @USER_REGION_ID
 is not empty AND ROWCOUNT(@PACKAGE_rows)  > 1 THEN  
 ]%% 

 condition 1

 %%[ELSE]%% 

 condition 2 

 %%[ENDIF]%%

Even if my variable USER_REGION_ID is populated I always see the condition 2 I don't see what I am missing...

1 Answer 1

2

It'd be something like this:

 %%[ 

 SET @PACKAGE_rows = lookuporderedrows("TABLE","10","ORDER DESC","CRITERIA","True")  
 SET @USER_REGION_ID = lookup("CONTACTS","region_id","email", @USER_EMAIL) 

 IF not empty(@USER_REGION_ID) AND rowcount(@PACKAGE_rows) > 1 THEN  
 ]%% 

 condition 1

 %%[ELSE]%% 

 condition 2 

 %%[ENDIF]%%

Reference

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .