+ Start a Discussion
TigerPowerTigerPower 

IF field ISPICKVAL, another field must be null (NOT PICKVAL)

Hey, how can I do this:

If one picklist field has value (any other than "none"), the other picklist field may not be selected (must be "none")?

Do  anyone have a solution for this? I've tried to reach to solution by using AND and OR statements (with ISPICKVAL), but I have been more or less validating the field to be required if the other field has been selected. So right now I'm doing it in the wrong way.

 

Regards,

TP

Best Answer chosen by Admin (Salesforce Developers) 
SteveMo__cSteveMo__c

are you looking for the liter value "None" in your picklists or do you really mean "no values selected"?

 

depending on what you want one of these should work for you:

 

AND(
NOT(ISBLANK(TEXT(PicklistField_1))),
NOT(ISBLANK(TEXT(PicklistField_2))))


AND(
TEXT(PicklistField_1) <> "None",
TEXT(PicklistField_2) <> "None"))

 

All Answers

SteveMo__cSteveMo__c

are you looking for the liter value "None" in your picklists or do you really mean "no values selected"?

 

depending on what you want one of these should work for you:

 

AND(
NOT(ISBLANK(TEXT(PicklistField_1))),
NOT(ISBLANK(TEXT(PicklistField_2))))


AND(
TEXT(PicklistField_1) <> "None",
TEXT(PicklistField_2) <> "None"))

 

This was selected as the best answer
TigerPowerTigerPower

Great,

thanks a lot Stevemo!! The first one worked fine with my challenge type of thing. Happy!!

SteveMo__cSteveMo__c

No problem, you owe me a beer (and I like to drink THESE!) -> http://beeradvocate.com/beer/profile/863/7971

Matt ChisamMatt Chisam
@steve this just helped me as well.  Not nearly as much as what Power of One has done for me, but my Inside Sales office is literally a block from Russian River Brewery (the original).  You're welcome to visit any time!