• Chris Paris
  • NEWBIE
  • 35 Points
  • Member since 2015

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 4
    Questions
  • 6
    Replies
I am trying to create a validation rule which references a picklist field [Field A] and a formula field(text) [Field B]

Field A has options A1, A2, A3 = picklist 
Field B has options B1, B2, B3 = Formula

How would I create a validation rule that allows for the following conditions, if any are met: 
If Field A = A1 and Field B = B1
If Field A = A2 and Field B = B1 or B2
if Field A = A3 and Field B = B1 or B2 or B3

The formula I am attempting to write is : 
If (and( ispickval(Field A = A1, Contains(Field B = B1),,
If (and(ispickval(field A = A2, OR(Contains(Field B = B1, Contains(Field B = B2),,
If (and(ispickval(field A = A3, OR(Contains(field b = B1, Contains(Field B = B2, Contains(Field B = B3,,
)))

Is it appropriate to use a 'IF" statement or would an "OR" statement be more appropriate?

Any help would be grateful!

Thanks,
I know this is likely a quick fix but we are trying to add in a new value to an existing working validation formula.  Currently, the existing validation rule below works to freeze opportunties from editing when the approval status is "sent for approval".  

The formula : 
AND(((ISPICKVAL( PRIORVALUE(Approval_Status__c),"Sent for Approval"))),NOT(OR($Profile.Name = "System Administrator", $Profile.Name = "Finance and Administration", $Profile.Name = "Finance Testing", $Profile.Name = "Sales Testing" )))

We are trying to use the formula above to filter for Approval Status both "Sent for Approval" and "Approved".  Any help would be great!

Many Thanks!
I have a requirement to create a validation rule to prevent transferring of records outside of a role.  I would like to allow users of a role to transfer objects owned by users in their role.  Any users outside of their role would not have permission to transfer records.  

Currently, our security is set to private and we enable view access to all accounts,leads,opportunity objects.  We have in place sharing rules per object per role, that give access to users within their respective role to edit those objects.  People outside that immediate role, do not have access to edit those objects.

The solution provides this : 

Mary in Role A
Joe in Role A
Bob in Role B

Mary can transfer an account that Joe owns into her name, but cannot transfer an account that Bob owns.  Bob cannot transfer Mary or Joe's account into his name.  

Is there a formula to use for a validation rule to only allow transferring objects based on roles as described in the example above?

Thanks!
I have a requirement to create a validation rule to prevent transferring of records outside of a role.  I would like to allow users of a role to transfer objects owned by users in their role.  Any users outside of their role would not have permission to transfer records.  

Currently, our security is set to private and we enable view access to all accounts,leads,opportunity objects.  We have in place sharing rules per object per role, that give access to users within their respective role to edit those objects.  People outside that immediate role, do not have access to edit those objects.

Since transfer record is a binary option controlled on profiles, is there a validation rule that can be put on objects to control the transferring permission for the need described above?


Thanks!
I am trying to create a validation rule which references a picklist field [Field A] and a formula field(text) [Field B]

Field A has options A1, A2, A3 = picklist 
Field B has options B1, B2, B3 = Formula

How would I create a validation rule that allows for the following conditions, if any are met: 
If Field A = A1 and Field B = B1
If Field A = A2 and Field B = B1 or B2
if Field A = A3 and Field B = B1 or B2 or B3

The formula I am attempting to write is : 
If (and( ispickval(Field A = A1, Contains(Field B = B1),,
If (and(ispickval(field A = A2, OR(Contains(Field B = B1, Contains(Field B = B2),,
If (and(ispickval(field A = A3, OR(Contains(field b = B1, Contains(Field B = B2, Contains(Field B = B3,,
)))

Is it appropriate to use a 'IF" statement or would an "OR" statement be more appropriate?

Any help would be grateful!

Thanks,
I know this is likely a quick fix but we are trying to add in a new value to an existing working validation formula.  Currently, the existing validation rule below works to freeze opportunties from editing when the approval status is "sent for approval".  

The formula : 
AND(((ISPICKVAL( PRIORVALUE(Approval_Status__c),"Sent for Approval"))),NOT(OR($Profile.Name = "System Administrator", $Profile.Name = "Finance and Administration", $Profile.Name = "Finance Testing", $Profile.Name = "Sales Testing" )))

We are trying to use the formula above to filter for Approval Status both "Sent for Approval" and "Approved".  Any help would be great!

Many Thanks!
I have a requirement to create a validation rule to prevent transferring of records outside of a role.  I would like to allow users of a role to transfer objects owned by users in their role.  Any users outside of their role would not have permission to transfer records.  

Currently, our security is set to private and we enable view access to all accounts,leads,opportunity objects.  We have in place sharing rules per object per role, that give access to users within their respective role to edit those objects.  People outside that immediate role, do not have access to edit those objects.

The solution provides this : 

Mary in Role A
Joe in Role A
Bob in Role B

Mary can transfer an account that Joe owns into her name, but cannot transfer an account that Bob owns.  Bob cannot transfer Mary or Joe's account into his name.  

Is there a formula to use for a validation rule to only allow transferring objects based on roles as described in the example above?

Thanks!
I have a requirement to create a validation rule to prevent transferring of records outside of a role.  I would like to allow users of a role to transfer objects owned by users in their role.  Any users outside of their role would not have permission to transfer records.  

Currently, our security is set to private and we enable view access to all accounts,leads,opportunity objects.  We have in place sharing rules per object per role, that give access to users within their respective role to edit those objects.  People outside that immediate role, do not have access to edit those objects.

Since transfer record is a binary option controlled on profiles, is there a validation rule that can be put on objects to control the transferring permission for the need described above?


Thanks!